Object-Oriented vs. Object-Based: a Simplified Comparison

Object oriented languages follows all the concepts of OOP whereas, Object based languages don't follow all the concepts like inheritance and polymorphism.

Object-Oriented Programming (OOP) and Object-Based Programming (OBP) share similarities in their use of objects, but there are notable differences between the two programming paradigms.

Object-Oriented Languages (OOP) follow all the concepts of OOP such as Abstraction, Inheritance, Polymorphism and Encapsulation.

Whereas Object-based languages don’t follow all the concepts of OOPs like inheritance and polymorphism. These languages do support Abstraction and Encapsulation, but the features are very limited.

Another major difference is the use of built-in objects. Object-Oriented languages do not have the inbuilt objects whereas Object-based languages have the inbuilt objects, for example, JavaScript has window object.

Module HelloWorld
    Sub Main()
        Console.WriteLine("Hello, World!")
        Console.ReadLine()
    End Sub
End Module

The above example is a simple Visual Basic program that prints Hello World to the console. It uses the built-in Console object.

class Greeting:
    def __init__(self, message):
        self.message = message

    def display_message(self):
        print(self.message)

# Creating an instance of the Greeting class
hello_world = Greeting("Hello, World!")

# Calling the display_message method to show the greeting
hello_world.display_message()

The above example is a simple Python program that prints Hello World to the console. It shows the features of Object Oriented Programming.

Differences between Object Oriented and Object Based Languages Simplified

Object Oriented LanguagesObject Based Languages
follows all concepts of Object Oriented Programming
* Encapsulation
* Abstraction
* Inheritance
* Polymorphism
Don’t follow all the concepts of OOP like Inheritance or Polymorphism
Don’t have any built-in objects, developers create and work with objects of built-in classesOffer built-in objects such as window (JavaScript)
Common Examples are C#, Java, Python etc.JavaScript (to some extent), Visual Basic 6, and early versions of JavaScript before it became more object-oriented with ES6.
Ram
Ram

I'm a full-stack developer and a software enthusiast who likes to play around with cloud and tech stack out of curiosity. You can connect with me on Medium, Twitter or LinkedIn.

Privacy Overview
Referbruv

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.

Strictly Necessary Cookies

Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.

3rd Party Cookies

This website uses Google Analytics to collect anonymous information such as the number of visitors to the site, and the most popular pages.

Keeping this cookie enabled helps us to improve our website.