Every Java Program is Object Oriented

Our Java instructor always asks us to prove that "every Java program is object oriented"

How can I prove this to be true?

+3
source share
3 answers

Because you cannot have a core that is not part of the class. Therefore, a class must exist in order to have a valid program.

But this is really nit-picking, because in fact you do not need to instantiate this class to do something. You can write a complete program using only static methods that do not create any objects at all.

Whether this is a useful program without using objects such as System.outis another matter.

OO , Java OO, , , ( ). .

+7

. . , Java - .

+2

Each java program is not object oriented due to the presence of primitives and statics.

-1
source

Source: https://habr.com/ru/post/1796502/


All Articles