Programming languages are generally built on certain models or paradigms to ensure the code behaves predictably. As we have learnt so far, a paradigm is defined as the style of writing a program and it helps to reduce flow complexity and determine the flow of execution. Now there are several paradigms, we have declarative, procedural, OOP, functional, logic and so much more. Programs and programming languages can choose or make use of multiple paradigms because these paradigms are in a way mutually exclusive. Python is primarily object oriented but its also procedural and functional. In previous articles, we discussed about the procedural programming and functional programming and how they both work. In this article, we will discuss about the Object Oriented Programming(OOP) paradigm.
OOP is one of the most widely used programming paradigms today due to the growing popularity of the languages that use it ranging from Java, Python, C++ and more. The ability of Object Oriented Programming(OOP) to translate real world problems into code makes it a very good option for various programming languages. It also has high modularity, which makes code easier to understand, makes it reusable, adds layers of abstraction and allows for code blocks to be removed between projects. OOP has certain components that make up the paradigm. It also has several concepts that supports the paradigm. Let us now take a look at this components and concepts.
There are three key components of Object Oriented Programming. These are:
These concepts include inheritance, polymorphism, encapsulation and abstraction.
In conclusion, we now know what Object Oriented Programming is, its usefulness, its components and the various concepts that support it. As mentioned earlier, OOP is one of the most widely used paradigms for programming languages. Python for example mainly uses object oriented programming and then the procedural and functional programming. This makes OOP an important paradigm to us as Python developers and as such heightens the need to know and digest fully the concept of OOP(Object Oriented Programming).
Introduction In the fast paced world of technology, learning a versatile and high-in-demand programming language…
Introduction User Authentication policy is a very crucial process for every application and organization. It…
Introduction In previous articles, we have learnt about Django, how it works and how we…
Introduction In this article, we shall learn how to build and implement a blog app.…
Introduction In this article, we shall use a database for the first time to build…
Introduction In this article, we will build a pages app that has a homepage and…