Keshav Sir Imp Java Questions
Keshav Sir Imp Java Questions
Set 1:
1. What is class?
2. What is object or instance of class?
3. What is Member variables, how it is different from local variables
4. What is static variables? explain
5. What is non-static variables or instance variables? explain
6. How to access static members? Explain
7. How to access non-static members of class? Explain
8. How to create an instance of class? Explain
9. What are the difference between static and non-static members of class
10. Give example when to use static variables and non-static variables
11. What is reference variables? How to create it?
12. What is primitive variables in java? how to declare it?
13. What is non-primitive variables in Java? how to declare it?
14. Explain how many ways member variables can be initialized?
15. explain static blocks and non-static blocks
16. What is constructors? why it is required?
17. Does every class has constructor?
18. What is default constructor?
19. What is parameterized constructor?
20. What is user defined constructor?
21. What is constructor Overloading?explain its benefit
22. Explain this keyword, what it contains and how it is useful
23. Explain this() statement, explain why it is required?
24. Does constructor has return type?
25. What does new operator used for and what it returns
26. Does java supports pass by reference? why
27. Does constructor be static?
28. Does constructor be inherited?
29. Can we delcare constructor as private?
30. What is the access of default constructor?
31. Can we override Constructor of class?
32. What is constructor calling or constructor chaining?
33. Explain super() statement, explain why it is required?
34. what is the difference between this() and super()
35. Explain super keyword, what is the use of it?
Set 3: