since Java have primitive data types, I think its not pure OO
Java is not a true object-oriented language.One of the requirements for such a title is that everything must be an object. Java contains non-object primitive values (such as int, float, boolean, etc.).
No, it is not strictly object oriented. Java still maintains the concept of primitive data types, such as char, int, long, float, double, boolean. And as such, these are not objects. In a true object oriented language, everything would be represented as an object, including operators. sory but wappers implement this concept n everything in java done by a class n a object it strickly follow the 3 rules of oops for detail refers java2 complete reference chapter2
C++ is based on C. C was not object oriented, therefore the language was not made to be object oriented and moreover C++ is not a "true OOP language". It is simply a non-OOP language with OOP functionality built onto it.
Java is a OOP language and it is not a pure Object Based Programming Language.Many languages are Object Oriented. There are seven qualities to be satisfied for a programming language to be pure Object Oriented. They are:Encapsulation/Data HidingInheritancePolymorphismAbstractionAll predefined types are objectsAll operations are performed by sending messages to objectsAll user defined types are objects.Java is not because it supports Primitive datatype such as int, byte, long... etc, to be used, which are not objects.Contrast with a pure OOP language like Smalltalk, where there are no primitive types, and boolean, int and methods are all objects.
No reason. It is not even true, on the first place.
No; C++ is.
True
true
That is false; the very definition of object-oriented programming is to create objects that model real objects, which places an emphasis on data encapsulation, polymorphic objects, and so on to reduce code complexity, common programming errors, and other problems associated with a non-object-oriented language. The procedures are not nearly as important as the objects that are designed.
There are relatively few 100% object-oriented programming languages, with C#, Ruby and SmallTalk being notable exceptions. Languages such as Java are not 100% object-oriented purely because they still maintain the concept of primitive data types, such as int and char, which are simply not capable of being treated as true objects.
'instanceof' is an operator that tests if the object to which this is applied is of a specific type or its descendent. You can safely typecast the object to the type tested if instanceof returns true.
Yes! It's an incredible scripting language! And very powerful once you get used to it. I am a c++ programmer and am learning Ruby and all I wish for is that it would be a faster language. This is one area where C++ is better. And that's it! Its a TRULY object-oriented language (not just oriented it a true objective language, hehe). Everything is an object there, not like in C++, which has also primitive types etc. Even operators are objects, and numbers too. You can do this for example:8.to_swhich means that you can call methods on numbers, like in this case, where i called "to_s" on the number 8.The result would be:"8"8 as a string, since to_s is a method that converts an object (eight in our case) to string.If you have a chance learn it! Its very rewarding, and I am saying that as a (still) only student of Ruby :)