Base Classes are A, B, C and their respective Child classes are A1, B1, C1.
-> A class constructor uses two parameters. (B and C)
Like, A (B *b, C *c).
-> A1 class constructor uses two parameters B1 and C1 and I also want to call A constructor at the same time with passing argument B and C.
I have implemented it by this way : A1 (B *b, C *c, B1 *b1, C1 *c1) : A(b,c).
-> But the problem here is I have to maintain two copies; Like base b and child b1. Before calling I have to prepare both b and b1 separately.
Is there any better way to implement it?
What I have tried:
A (B *b , C *c).
A1 (B *b, C *c, B1 *b1, C1 *c1) : A(b,c).