Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Java by (6.1k points)
As I have just started learning Java. So I want to know whether Java is an object-oriented language or not?

1 Answer

0 votes
by (11.7k points)

Fully object oriented language is one where everything inside program is treated as an object. But Java on the other hand has data types like boolean, char, short, int, long, float, double, different kinds of arithmetic, logical and bitwise operator like +, -. *, /, &&, || etc. which are not treated as objects.

Though Java is the most popular and successful Object Oriented Programming language which also got some functional programming touch in Java 8

Object-oriented programming must have the things listed down below:

  • 1. Encapsulation/Data Hiding

  • 2. Inheritance

  • 3. Polymorphism

  • 4. Abstraction

  • 5. All predefined types are objects

  • 6. All operations are performed by sending messages to objects

  • 7. All user-defined types are objects.

Java does not satisfy all of these qualities listed above, which is why it is not purely Object Oriented.

Browse Categories

...