Which is the valid declarations within an interface definition ?
A.public double method();
B. public final double method();
C. static void method(double d1);
D.protected void method(double 1);
View AnswerAns: public double method();
Which operator is used by java to free the memory allocated to an object when the object is no longer needed ?
D.None of these
View AnswerAns: None of these
What is error in this code ?
A.b can not contain this value,limited by its range.
B. type mismatch,cant convert from int to byte.
C. b can not contain value 50.
View AnswerAns: no error.
Which one of the following conversion does not obeys WIDENING term ?
A.long to double
B. int to char
C. short to int
D.byte to long
View AnswerAns: int to char
Which of the following is true ?
1. A class can extend more than one class
2. A class can extend only one class but many interfaces.
3. An interface can extend many interfaces.
4. An interface can implement many interfaces.
5. A class can extend one class and implement many interfaces.