Explain OOPs concept in python with programatic examples

0 votes
Mar 18, 2019 in Python by Sathya
262 views

2 answers to this question.

–1 vote
answered Mar 19, 2019 by Srinesh
0 votes

OOP reflects the real world behavior of how things work. It is important because

  • It make visualization easier because it is closest to real world scenarios.
  • You can reuse the code, this saves time, and shrinks your project.
  • Once you know the concept, it makes you a cooler coder among your friends ;) .

There are 3 basic features of object oriented programming language:

  • Inheritance
  • Polymorphism
  • Encapsulation

By using these features you can easily reuse your program or part of your program. Object oriented programming provides you a power to do programming in a very effective manner. Learn OOP concept and implement it in your daily programs.

answered Jun 24 by rahul
• 360 points

Related Questions In Python

0 votes
1 answer
0 votes
1 answer

Can someone explain the behaviour of increment and decrement operators in python

down voteaccepted ++ is not an operator. It is ...READ MORE

answered May 15, 2018 in Python by aryya
• 7,380 points
665 views
0 votes
1 answer

Create an empty list in python with certain size

Try this instead: lst = [None] * 10 The ...READ MORE

answered Aug 2, 2018 in Python by bug_seeker
• 15,480 points
11,384 views
0 votes
1 answer

Examples for string find in Python

you can use str.index too: >>> 'sdfasdf'.index('cc') Traceback ...READ MORE

answered Aug 29, 2018 in Python by Priyaj
• 57,640 points
98 views
0 votes
1 answer

How to replace values with None in Pandas data frame in Python?

Actually in later versions of pandas this ...READ MORE

answered Aug 30, 2018 in Python by Priyaj
• 57,640 points
6,414 views
0 votes
1 answer

How can I logarithmic axes with matplotlib in python?

You can use the Axes.set_yscale method. That allows you ...READ MORE

answered Oct 15, 2018 in Python by charlie_brown
• 7,780 points
1,216 views
0 votes
1 answer

Open multiple files using with open() in Python?

Just replace and with , and you're done: with open('a', 'w') as ...READ MORE

answered Oct 31, 2018 in Python by Priyaj
• 57,640 points
5,724 views
0 votes
1 answer

Real-world examples of applications in python?

You can view this reference here: Python projects ...READ MORE

answered Nov 2, 2018 in Python by Nabarupa
433 views
0 votes
3 answers

What is the python keyword “with” used for?

The with statement in Python simplifies exception ...READ MORE

answered Jul 19, 2019 in Python by rahul
• 360 points
229 views
0 votes
2 answers

How to use not equal operator in python

You can use "!=" and "is not" ...READ MORE

answered Mar 17 in Python by rahul
• 360 points
51,780 views