Java Interview Faqs
1. What is java run time environment?
2. How java is platform independent language?
3. What is difference between compiler and interpreter?
4. Java is secure language. Why?
5. Why main function in java is static?
6. What is abstract class and what is use of abstract class?
7. Why a class cannot be static?
8. Why abstract class cannot be final?
9. What is final class, final method and final variable?
Answer:
A final class is special type of class which cannot be inherited i.e. we cannot create any subclass of final class. All the methods and variables of final class is also final.
A final method is special type of method which cannot be overridden in the subclass.
A final variable is special type of variable which after assigning a value at the time of declaration we cannot modified its value. It is necessary to initialize the final variable at the time of declation.
10. What is default access specificer?
11. What is static import in java?
12. What is difference between checked and unchecked exception?
13. What is wrapper class in java?
14. What is generic?
15. What is difference between throw and throws keyword?
No comments:
Post a Comment