Java - Interview Questions and Answers for 'Oops features' | Search Java Interview Question - javasearch.buggybread.com
Javasearch.buggybread.com
Share

Search Java Interview Questions


 2137 questions in repository.
 There are more than 200 unanswered questions.
Click here and help us by providing the answer.
Label / Company      Label / Company / Text

   



Interview Questions and Answers for 'Oops features' - 6 question(s) found - Order By Newest

 Q1. Can you give a real world example of Encapsulation and Abstraction ?Core Java2016-05-29 13:47:31

Ans. Car Engine is an example of encapsulation and abstraction. You ignite the car using an interface called starter and least bothered about how the tire actually moves (This is abstraction). The engine encapsulates the complete process to itself only and doesn't allow you to start the other components like the radiator etc ( this is excapsulation )

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     encapsulation  abstraction  oops  oops features  java features     MAQ Software  Daffodil Software  Quickstart Global  Alliance Global Services  InfoStretch  Intelligrape  Prowareness  Support.com  Cognizant (CTS)  BNT SOFT  Clairvoyant TechnoSolutions  Suyati Technologies  3DPLM Software Solutions


 Q2. Which of the following Java feature promotes access protection or Hiding ?

a. Inheritance
b. Encapsulation
c. Abstraction
d. Composition
Core Java
Anonymous
Ans. Encapsulation

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   java concepts   java features   oops concepts   oops features   access protection   information hiding


 Q3. Explain OOPs Core Java2017-06-13 08:25:45

Ans. OOPs or Object Oriented Programming is a Programming model which is organized around Objects instead of processes. Instead of a process calling series of processes, this model stresses on communication between objects. Objects that all self sustained, provide security by encapsulating it's members and providing abstracted interfaces over the functions it performs. OOP's facilitate the following features

1. Inheritance for Code Reuse
2. Abstraction for modularity, maintenance and agility
3. Encapsulation for security and protected
4. Polymorphism for flexibility and interfacing

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     oops  oops features     Trimax IT Infrastructure & Services  Aricent  HCL Technologies   Tata Consultancy (TCS)  Infosys      basic        frequent


Very frequently asked. Usually among very first few questions.
 Q4. Define encapsulation in Java ?Core Java2017-06-12 07:55:47

Ans. Encapsulation is a feature of OOP's that binds the data and it's associated methods together as a single unit and facilitate protection and data hiding by providing minimal interface to outside. For example - member variables are declared private and are accessed through public methods. Moreover we have private methods that can only be used internally and hence providing minimal interface to outside class through use of public methods.

  Sample Code for encapsulation

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     encapsulation  oops  oops concepts  oops features     Trimax IT Infrastructure & Services      Basic        frequent


 Q5. Give an example of how Object Oriented Programming Concepts can be implemented.Design2017-06-18 06:45:37

 This question was recently asked at 'Accenture'.This question is still unanswered. Can you please provide an answer.


 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     oops  oops example  oops concepts  oops features     Accenture      basic        frequent


 Q6. Which of the OOP's features facilitate dependency injection ? Design2017-08-06 19:11:22

Ans. Inheritance , Runtime Polymorphism and Composition.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     dependency injection  inversion of control  ioc  oops  oops features




Subscribe to Java News and Posts. Get latest updates and posts on Java from Buggybread.com
Enter your email address:
Delivered by FeedBurner



comments powered by Disqus
 

Help us and Others Improve. Please let us know the questions asked in any of your previous interview.

Any input from you will be highly appreciated and It will unlock the application for 10 more requests.

Company Name:
Questions Asked:
         

X Close this

X Close this

Help Us Improve.
Please share your
interview experience.

Company Name:   


Questions Asked: