K
Kevin
abstract class A
{
public A()
{
}
public A(int i, int j)
{
}
}
public class B extends A
{
}
B does not have the corrresponding constractor of B(int i, int j) from
A, though B may have all other fucntions of A.
That's to say:
B b = new B(10, 14); will not work.
Isn't it strange?
I found the behavior of constractors are pretty different from normal
functions. How to explain it?
Thanks!
{
public A()
{
}
public A(int i, int j)
{
}
}
public class B extends A
{
}
B does not have the corrresponding constractor of B(int i, int j) from
A, though B may have all other fucntions of A.
That's to say:
B b = new B(10, 14); will not work.
Isn't it strange?
I found the behavior of constractors are pretty different from normal
functions. How to explain it?
Thanks!