Hi All
Could anyone of you please give me the correct answer for the folowing code:
Given the following class definition:
1. public class deriveddemo extends demo {
2. int M,N,L;
3. public deriveddemo(int x,int y) {
4. M=x;N=y;
5. }
6.public deriveddemo(int x) {
7. super(x);
8. }
9. }
which of the following constructor signatures must exist
in the demo class for deriveddemo to compile correctly?
a.public Demo(int a,int b)
b.public Demo(int c)
c.public Demo()
I think the correct answer is only b.But the correct answer
is b and c.Howcome c is correct ans?
Thanks and Regards
Priya