1. Given the following piece of code:
public class School{
public abstract double numberOfStudent();
}
which of the following statements is true?
public class School{
public abstract double numberOfStudent();
}
2. Which of the following class definitions defines a legal abstract class?
3. Which of the following declares an abstract method in an abstract Java class?
4. Which of the following statements regarding abstract classes are true?
5. Suppose A is an abstract class, B is a concrete subclass of A, and both A and B have a default constructor. Which of the following is correct?
1. A a = new A();
2. A a = new B();
3. B b = new A();
4. B b = new B();
1. A a = new A();
2. A a = new B();
3. B b = new A();
4. B b = new B();