Guvi-blog-logo

Best Interview Questions for OOPS/Inheritance

CTD26920188389

  1. Object-oriented programming uses classes and objects. What are classes and what are objects? What is the relationship between classes and objects?
  2. Explain carefully what null means in Java, and why this special value is necessary.
  3. What are the three parts of a simple empty class explain with example?
  4. What is a constructor? What is the purpose of a constructor in a class?
  5. What is meant by the terms instance variable and instance method?
  6. Explain what is meant by the terms subclass and superclass.
  7. Explain the term polymorphism.
  8. Java uses “garbage collection” for memory management. Explain what is meant here by garbage collection. What is the alternative to garbage collection?
  9. Bring out the importance of inheritance with the help of an example?
  10. When do we declare the members of the class as static explain with example?
  11. When do we declare a method or class as final explain with example?
  12. What is the advantage of using “this” keyword, explain?
  13. Explain about inner classes with an example?
  14. Explain how super keyword is used in overriding the methods?
  15. Explain the use of super() method in invoking a constructor?
  16. When does a base class variable get hidden, Give reasons?
  17. Explain with an example how we can access a hidden base class variable?

Suggested Course : https://www.guvi.in/course-detail?course=cpp

Contact Form

By clicking 'Submit' you Agree to Guvi Terms & Conditions.

Our Learners Work at

Our Popular Course

Share this post

Author Bio

admin
admin

Our Live Classes

Learn Javascript, HTML, CSS, Java, Data Structure, MongoDB & more
Learn Python, Machine Learning, NLP, Tableau, PowerBI & more
Learn Selenium, Python, Java, Jenkins, Jmeter, API Testing & more
Learn Networking, Security Testing, IAM, Access Management & more

Hey wait, Don’t miss New Updates from GUVI!

Get Your Course Now

Related Articles