SlideShare a Scribd company logo
OOP Concepts Created by - Om Vikram Thapa
OOP vs. POP Emphasis is on data. Divides code into logical chunks individuals of a team can be experts in, and outsiders can understand via interfaces  Supports code evolution: internals can always be re-written as long as interface stays the same. Data security. Emphasis is on procedures. This programming technique can only be used in a very small program. if the same statement sequence is needed at different locations, the sequence must be copied. If an error needed to be modified, every copy needs to be modified.
Procedure Program view Main Program Data Procedure 1 Procedure 2 Procedure 3
OOP Program view Data Object 3 Data 3  +   Procedures 3 Object 2 Data 2  +   Procedures 2  Object 4 Data 4  +   Procedures 4 Object 1 Data 1 +Procedures 1
Main OOP Concepts: Object Class Abstraction  Encapsulation Inheritance Polymorphism
Objects and Class An  object  represents something with which we can interact in a program A class represents a concept, and an object represents the embodiment of a class A class is a blueprint for an object. A class can be used to create multiple objects A program models a world of interacting objects. Objects create other objects and “send messages” to each other. Each object belongs to a class; a class defines properties of its objects.  The data type of an object is its class.
Abstraction One of the chief advantages of object-oriented programming is the idea that programmers can essentially focus on the “big picture” and ignore specific details regarding the inner-workings of an object. This concept is called  abstraction .
Encapsulation Abstraction in OOP is closely related to a concept called  encapsulation .  Data and the ways to get at that data are wrapped in a single package, a class. The only way to access such data is through that package. This idea translates to information hiding.
Inheritance Another of the main tenets of OOP is  inheritance . Inheritance allows programmers to create new classes from existing ones. A child class inherits its properties and attributes from its parents, which programmers can change.
Polymorphism Polymorphism describes how programmers write methods to do some general purpose function.  Different objects might perform polymorphic methods differently. The ability of objects to respond differently to the same message or function call.
Examples Object legislates how its data may be accessed ( encapsulation ) Once you have created an ADT for complex numbers, say Complex, you can use it in the same way like well-known data types such as integers. Encapsulation provides a way to protect data from accidental corruption. One class may be a special case of another ( inheritance ) Rectangle is like a square, plus a second (possibly) distinct value Colored-Rectangle is like a rectangle, plus the concept of color Different classes in a hierarchy behave correctly( polymorphism ) shape.getArea(a,b) = len*wid, if shape is a rectangle shape.getArea(a) = PI*r2, if shape is a circle

More Related Content

PPTX
Introduction to Object Oriented Programming
Md. Tanvir Hossain
 
PPTX
the Concept of Object-Oriented Programming
Aida Ramlan II
 
PPTX
General oops concepts
nidhiyagnik123
 
PPTX
Object Oriented Concept
D Nayanathara
 
PPTX
Object Oriented Programming Concepts
Abhigyan Singh Yadav
 
PPTX
Introduction to Object Oriented Programming
Moutaz Haddara
 
PPTX
Object oriented programming concepts
rahuld115
 
Introduction to Object Oriented Programming
Md. Tanvir Hossain
 
the Concept of Object-Oriented Programming
Aida Ramlan II
 
General oops concepts
nidhiyagnik123
 
Object Oriented Concept
D Nayanathara
 
Object Oriented Programming Concepts
Abhigyan Singh Yadav
 
Introduction to Object Oriented Programming
Moutaz Haddara
 
Object oriented programming concepts
rahuld115
 

What's hot (20)

PPTX
Oops concept in c++ unit 3 -topic 4
MOHIT TOMAR
 
PPT
Object Oriented Programming Concepts
thinkphp
 
PPT
2 Object Oriented Programming
Praveen M Jigajinni
 
PPT
Oops
Prabhu R
 
PPT
Object Oriented Language
dheva B
 
PPTX
Object oriented programming concept
Pina Parmar
 
PPTX
Characteristics of oop
Rasim Izhar Ali
 
PPTX
Fundamentals of OOP (Object Oriented Programming)
MD Sulaiman
 
PPT
General OOP concept [by-Digvijay]
Digvijay Singh Karakoti
 
PPT
SEMINAR
priteshkhandelwal
 
PPTX
Basic Concepts Of OOPS/OOPS in Java,C++
Guneesh Basundhra
 
PDF
Concepts of OOPs
Essay Corp
 
PPTX
OOP Introduction with java programming language
Md.Al-imran Roton
 
PDF
Introduction to object oriented programming
Abzetdin Adamov
 
PPTX
Introduction to oop
colleges
 
PPTX
Oo ps concepts in c++
Hemant Saini
 
PPTX
concept of oops
prince sharma
 
PPT
Basic concepts of object oriented programming
Sachin Sharma
 
Oops concept in c++ unit 3 -topic 4
MOHIT TOMAR
 
Object Oriented Programming Concepts
thinkphp
 
2 Object Oriented Programming
Praveen M Jigajinni
 
Oops
Prabhu R
 
Object Oriented Language
dheva B
 
Object oriented programming concept
Pina Parmar
 
Characteristics of oop
Rasim Izhar Ali
 
Fundamentals of OOP (Object Oriented Programming)
MD Sulaiman
 
General OOP concept [by-Digvijay]
Digvijay Singh Karakoti
 
Basic Concepts Of OOPS/OOPS in Java,C++
Guneesh Basundhra
 
Concepts of OOPs
Essay Corp
 
OOP Introduction with java programming language
Md.Al-imran Roton
 
Introduction to object oriented programming
Abzetdin Adamov
 
Introduction to oop
colleges
 
Oo ps concepts in c++
Hemant Saini
 
concept of oops
prince sharma
 
Basic concepts of object oriented programming
Sachin Sharma
 
Ad

Viewers also liked (6)

PDF
OOP is more than Cars and Dogs
Chris Tankersley
 
PPT
Abhiram
Abhiram Sadhu
 
PPTX
Top down approach
Yiscah Etrof
 
PPT
Bottom up & top down tutorial 2
Darshiny Rajasegaran
 
PPTX
Introduction to Information Technology (IT)
Amber Bhaumik
 
PDF
Top Down and Bottom Up Design Model
Abdul Rahman Sherzad
 
OOP is more than Cars and Dogs
Chris Tankersley
 
Abhiram
Abhiram Sadhu
 
Top down approach
Yiscah Etrof
 
Bottom up & top down tutorial 2
Darshiny Rajasegaran
 
Introduction to Information Technology (IT)
Amber Bhaumik
 
Top Down and Bottom Up Design Model
Abdul Rahman Sherzad
 
Ad

Similar to OOP (20)

PDF
L1-Introduction to OOPs concepts.pdf
BhanuJatinSingh
 
PPT
Basic concepts of oops
Chandrakiran Satdeve
 
PPTX
Chapter 04 object oriented programming
Praveen M Jigajinni
 
PPTX
Object oriented programming
baabtra.com - No. 1 supplier of quality freshers
 
PPT
Share Unit 1- Basic concept of object-oriented-programming.ppt
hannahrroselin95
 
PDF
UNIT1- OBJECT ORIENTED PROGRAMMING IN JAVA- AIML IT-SPPU
ApurvaLaddha
 
PPTX
Intro to object oriented programming.pptx
RafiaZafar19
 
PPTX
1 unit (oops)
Jay Patel
 
PPTX
SKILLWISE - OOPS CONCEPT
Skillwise Group
 
PPTX
Object Oriented Programming Concepts Using C++
Mtnc BCA DEPARTMENT
 
PPTX
Object oriented programming 6 oop with c++
Vaibhav Khanna
 
PPTX
Unit - I Intro. to OOP Concepts and Control Structure -OOP and CG (2024 Patte...
babasahebgaikwad8
 
PPTX
chapterOne.pptxFSdgfqdzwwfagxgghvkjljhcxCZZXvcbx
berihun18
 
PDF
22601221182_RAHUL_MODAK_BCAC301.pdf
ssuser736e06
 
PPT
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
akashsachu221
 
PPTX
IET307 OOP - object oriented programming concepts.pptx
BasithAb2
 
PPTX
Object Oriented Programming Language is an oop
sanaiftikhar23
 
PDF
Procedural-vs-Object-Oriented-Programming (1).pdf
AnujMalviya12
 
PPTX
introduction of Object oriented programming
RiturajJain8
 
PPTX
Object Oriented Programming fundamentals.pptx
sanaiftikhar23
 
L1-Introduction to OOPs concepts.pdf
BhanuJatinSingh
 
Basic concepts of oops
Chandrakiran Satdeve
 
Chapter 04 object oriented programming
Praveen M Jigajinni
 
Share Unit 1- Basic concept of object-oriented-programming.ppt
hannahrroselin95
 
UNIT1- OBJECT ORIENTED PROGRAMMING IN JAVA- AIML IT-SPPU
ApurvaLaddha
 
Intro to object oriented programming.pptx
RafiaZafar19
 
1 unit (oops)
Jay Patel
 
SKILLWISE - OOPS CONCEPT
Skillwise Group
 
Object Oriented Programming Concepts Using C++
Mtnc BCA DEPARTMENT
 
Object oriented programming 6 oop with c++
Vaibhav Khanna
 
Unit - I Intro. to OOP Concepts and Control Structure -OOP and CG (2024 Patte...
babasahebgaikwad8
 
chapterOne.pptxFSdgfqdzwwfagxgghvkjljhcxCZZXvcbx
berihun18
 
22601221182_RAHUL_MODAK_BCAC301.pdf
ssuser736e06
 
Java Fundamentalojhgghjjjjhhgghhjjjjhhj.ppt
akashsachu221
 
IET307 OOP - object oriented programming concepts.pptx
BasithAb2
 
Object Oriented Programming Language is an oop
sanaiftikhar23
 
Procedural-vs-Object-Oriented-Programming (1).pdf
AnujMalviya12
 
introduction of Object oriented programming
RiturajJain8
 
Object Oriented Programming fundamentals.pptx
sanaiftikhar23
 

More from Om Vikram Thapa (20)

PDF
Next Set of Leaders Series
Om Vikram Thapa
 
PDF
Integration Testing at go-mmt
Om Vikram Thapa
 
PDF
Understanding payments
Om Vikram Thapa
 
PDF
System Alerting & Monitoring
Om Vikram Thapa
 
PDF
Serverless computing
Om Vikram Thapa
 
PDF
Sumologic Community
Om Vikram Thapa
 
PPTX
Postman Integration Testing
Om Vikram Thapa
 
PDF
Scalibility
Om Vikram Thapa
 
PDF
5 Dysfunctions of a team
Om Vikram Thapa
 
PDF
AWS Must Know
Om Vikram Thapa
 
PDF
Continuous Feedback
Om Vikram Thapa
 
PDF
Sql views, stored procedure, functions
Om Vikram Thapa
 
PDF
Confluence + jira together
Om Vikram Thapa
 
PDF
Understanding WhatFix
Om Vikram Thapa
 
PDF
Tech Recruitment Process
Om Vikram Thapa
 
PPTX
Jira Workshop
Om Vikram Thapa
 
PPT
Security@ecommerce
Om Vikram Thapa
 
PPT
Understanding iis part2
Om Vikram Thapa
 
PPT
Understanding iis part1
Om Vikram Thapa
 
PPT
.Net framework
Om Vikram Thapa
 
Next Set of Leaders Series
Om Vikram Thapa
 
Integration Testing at go-mmt
Om Vikram Thapa
 
Understanding payments
Om Vikram Thapa
 
System Alerting & Monitoring
Om Vikram Thapa
 
Serverless computing
Om Vikram Thapa
 
Sumologic Community
Om Vikram Thapa
 
Postman Integration Testing
Om Vikram Thapa
 
Scalibility
Om Vikram Thapa
 
5 Dysfunctions of a team
Om Vikram Thapa
 
AWS Must Know
Om Vikram Thapa
 
Continuous Feedback
Om Vikram Thapa
 
Sql views, stored procedure, functions
Om Vikram Thapa
 
Confluence + jira together
Om Vikram Thapa
 
Understanding WhatFix
Om Vikram Thapa
 
Tech Recruitment Process
Om Vikram Thapa
 
Jira Workshop
Om Vikram Thapa
 
Security@ecommerce
Om Vikram Thapa
 
Understanding iis part2
Om Vikram Thapa
 
Understanding iis part1
Om Vikram Thapa
 
.Net framework
Om Vikram Thapa
 

Recently uploaded (20)

PDF
Omica Pageant 2025- Premier beauty pageant platform
OmicaPageant
 
PDF
The Architecture of Change: Why Frameworks Outperform Willpower in Therapy
Identity Growth Journal
 
PPTX
Human_Self_Exploration1_Lecture-III.pptx
ssusera15ea5
 
PPTX
Holistic Development Role of Edu v5.pptx
ssusera15ea5
 
PDF
4th Industrial Revolution, Transition Period and Sectors
Sazzad Hossain Riju
 
PPTX
Understanding Value Education_Lect2.pptx
ssusera15ea5
 
PPTX
The Journey of Self Refinement and self improvement
Muhammad Musawar Ali
 
PDF
Despre calibrare: O abordare structurată
Răzvan Deaconescu
 
PPTX
Skincare: Know Your Skin, Build Your Routine
khushish167
 
PPTX
Healing Routine Presentation.exercisepptx
eman youssif
 
PPTX
Your Personal Growth Journal journaling.pptx
eman youssif
 
PPTX
Self-Care Toolbox.advices and developmentpptx
eman youssif
 
PPT
Life Skill_https://www.scribd.com/archive/plans?slideshare=true.ppt
machonvicoti
 
PPTX
Healing Portfolio Presentation.exercisepptx
eman youssif
 
PPTX
Combining Writing, Art, And Affirmations.pptx
eman youssif
 
PDF
The Human Edge: Why A.I. Can’t Steal Your Story!
vijitsrivastava083
 
PDF
Manual-of-Guerilla-Tactics To Protect You
bawga
 
PPTX
159f8c58-e1a2-42dd-a75d-4793a811a857.pptx
kewalsinghpuriya
 
PDF
Quarterly project_20250727_112257_0000.pdf
monteroemilia873
 
PPTX
Discipline and Positive Behaviour Plan for A Great Day
DarmawanAmbari2
 
Omica Pageant 2025- Premier beauty pageant platform
OmicaPageant
 
The Architecture of Change: Why Frameworks Outperform Willpower in Therapy
Identity Growth Journal
 
Human_Self_Exploration1_Lecture-III.pptx
ssusera15ea5
 
Holistic Development Role of Edu v5.pptx
ssusera15ea5
 
4th Industrial Revolution, Transition Period and Sectors
Sazzad Hossain Riju
 
Understanding Value Education_Lect2.pptx
ssusera15ea5
 
The Journey of Self Refinement and self improvement
Muhammad Musawar Ali
 
Despre calibrare: O abordare structurată
Răzvan Deaconescu
 
Skincare: Know Your Skin, Build Your Routine
khushish167
 
Healing Routine Presentation.exercisepptx
eman youssif
 
Your Personal Growth Journal journaling.pptx
eman youssif
 
Self-Care Toolbox.advices and developmentpptx
eman youssif
 
Life Skill_https://www.scribd.com/archive/plans?slideshare=true.ppt
machonvicoti
 
Healing Portfolio Presentation.exercisepptx
eman youssif
 
Combining Writing, Art, And Affirmations.pptx
eman youssif
 
The Human Edge: Why A.I. Can’t Steal Your Story!
vijitsrivastava083
 
Manual-of-Guerilla-Tactics To Protect You
bawga
 
159f8c58-e1a2-42dd-a75d-4793a811a857.pptx
kewalsinghpuriya
 
Quarterly project_20250727_112257_0000.pdf
monteroemilia873
 
Discipline and Positive Behaviour Plan for A Great Day
DarmawanAmbari2
 

OOP

  • 1. OOP Concepts Created by - Om Vikram Thapa
  • 2. OOP vs. POP Emphasis is on data. Divides code into logical chunks individuals of a team can be experts in, and outsiders can understand via interfaces Supports code evolution: internals can always be re-written as long as interface stays the same. Data security. Emphasis is on procedures. This programming technique can only be used in a very small program. if the same statement sequence is needed at different locations, the sequence must be copied. If an error needed to be modified, every copy needs to be modified.
  • 3. Procedure Program view Main Program Data Procedure 1 Procedure 2 Procedure 3
  • 4. OOP Program view Data Object 3 Data 3 + Procedures 3 Object 2 Data 2 + Procedures 2 Object 4 Data 4 + Procedures 4 Object 1 Data 1 +Procedures 1
  • 5. Main OOP Concepts: Object Class Abstraction Encapsulation Inheritance Polymorphism
  • 6. Objects and Class An object represents something with which we can interact in a program A class represents a concept, and an object represents the embodiment of a class A class is a blueprint for an object. A class can be used to create multiple objects A program models a world of interacting objects. Objects create other objects and “send messages” to each other. Each object belongs to a class; a class defines properties of its objects. The data type of an object is its class.
  • 7. Abstraction One of the chief advantages of object-oriented programming is the idea that programmers can essentially focus on the “big picture” and ignore specific details regarding the inner-workings of an object. This concept is called abstraction .
  • 8. Encapsulation Abstraction in OOP is closely related to a concept called encapsulation . Data and the ways to get at that data are wrapped in a single package, a class. The only way to access such data is through that package. This idea translates to information hiding.
  • 9. Inheritance Another of the main tenets of OOP is inheritance . Inheritance allows programmers to create new classes from existing ones. A child class inherits its properties and attributes from its parents, which programmers can change.
  • 10. Polymorphism Polymorphism describes how programmers write methods to do some general purpose function. Different objects might perform polymorphic methods differently. The ability of objects to respond differently to the same message or function call.
  • 11. Examples Object legislates how its data may be accessed ( encapsulation ) Once you have created an ADT for complex numbers, say Complex, you can use it in the same way like well-known data types such as integers. Encapsulation provides a way to protect data from accidental corruption. One class may be a special case of another ( inheritance ) Rectangle is like a square, plus a second (possibly) distinct value Colored-Rectangle is like a rectangle, plus the concept of color Different classes in a hierarchy behave correctly( polymorphism ) shape.getArea(a,b) = len*wid, if shape is a rectangle shape.getArea(a) = PI*r2, if shape is a circle