SlideShare a Scribd company logo
1 of 15
Click to edit Master title style
1
WITH REAL LIFE EXAMPLES
BASIC OOP
CONCEPTS
By
GROUP 2
Click to edit Master title style
2
Basic Concepts of Object-Oriented Programming
• Classes
• Objects
• Data Abstraction
• Encapsulation
• Inheritance
• Polymorphism
• Dynamic Binding
• Message passing
2
Four pillars of OOP concept
Click to edit Master title style
3
DATA ABSTRACTION
• Data Abstraction is the process of showcasing only
the required things to the outside world while hiding
the details.
• It is the most important pillar in OOPS.
• On using the example of mobiles ,
 While dialing some methods happen internally
which concatenate the numbers and displays it on
screen but what it is actually doing is unknown to us.
 Clicking on green button actual send signals to
calling person's mobile but we are unaware of how it 3
Click to edit Master title style
4
• In classes , we can create methods that can
be called and used by the users of the class
but users will have no idea what these
methods do internally.
4
Click to edit Master title style
5
ENCAPSULATION
• Data binding – binds data variables and
functions together in class.
• The data can be accessed only by the
functions within the class and not by the
outside world.
• It says how much access must be given to
particular details.
• This insulation of data is called data hiding/
information hiding.
5
Click to edit Master title style
6
Example 1 – Mobile phones
6
• When we switch on a Bluetooth,
we can connect to another
Bluetooth enabled device, but we
don’t have access to other mobile
features like dialing number,
accessing inbox etc.
• This is because Bluetooth has some
level of abstraction. Encapsulation
and abstraction go hand in hand.
• Similarly, when mobile A is
connected to mobile B and mobile
B is connected to mobile C via
Bluetooth , the A can’t connect to
C via B.
Click to edit Master title style
7
Example 2 – Human body
7
• Different body parts are bound to do
different functions.
• For example,
 Hands - Hold()
 Legs - Walk()
 Eyes - See()
Click to edit Master title style
8
INHERITANCE
• Ability to extend the functionality from base
entity in new entity belonging to same group.
• Helps to reuse functionality.
• 5 types:
1. Single level inheritance
2. Multi-level inheritance
3. Hybrid inheritance
4. Hierarchal inheritance
5. Multiple inheritance
8
Click to edit Master title style
9
Types Of Inheritance
9
Single level inheritance Multi-level inheritance
• Single base class & a single
derived class.
• More than one single level of
derivation.
Click to edit Master title style
1010
Hierarchal level inheritance Hybrid inheritance
• Multiple derived class would be extended
from base class.
• Similar to single level inheritance.
• Single, Multilevel & hierarchal inheritance
all together construct a hybrid
inheritance.
Click to edit Master title style
11
Multiple inheritance
Derived class will ex t en d from mu lt iple base
classes.
11
Click to edit Master title style
12
POLYMORPHISM
• Polymorphism can be defined as the ability of using same
name for doing different things.
• Many forms of single entity.
• Let's consider our example, Samsung mobile has a 5MP
camera available i.e. – it is having a functionality of, say,
CameraClick(). Now same mobile is having Panorama mode
available in camera, so functionality would be same but with
mode. This type is said to be Static polymorphism or
Compile time polymorphism.
12
Click to edit Master title style
13
• Another point where in function ,say, SendMessage()
was intended to send message to single person at a
time but suppose Nokia had given provision for
sending message to a group at once. i.e. - Overriding
the functionality to send message to a group. This
type is called Dynamic polymorphism or Runtime
polymorphism.
• For overriding you need to set the method, which can
be overridden to virtual & its new implementation
should be decorated with override keyword.
• By runtime polymorphism, we can point to any 13
Click to edit Master title style
14
“
Another trick in software is to avoid rewriting
the software by using a piece that's already
been written, so called component approach
which the latest term for this in the most
advanced form is what's called Object
Oriented Programming.
- Bill Gates
14
Click to edit Master title style
15
Thank You

More Related Content

What's hot

Basic Concepts of OOPs (Object Oriented Programming in Java)
Basic Concepts of OOPs (Object Oriented Programming in Java)Basic Concepts of OOPs (Object Oriented Programming in Java)
Basic Concepts of OOPs (Object Oriented Programming in Java)Michelle Anne Meralpis
 
Array of objects.pptx
Array of objects.pptxArray of objects.pptx
Array of objects.pptxRAGAVIC2
 
Classes and Objects in C#
Classes and Objects in C#Classes and Objects in C#
Classes and Objects in C#Adeel Rasheed
 
Object Oriented Programming Concepts
Object Oriented Programming ConceptsObject Oriented Programming Concepts
Object Oriented Programming Conceptsthinkphp
 
Dynamic memory allocation in c++
Dynamic memory allocation in c++Dynamic memory allocation in c++
Dynamic memory allocation in c++Tech_MX
 
object oriented Programming ppt
object oriented Programming pptobject oriented Programming ppt
object oriented Programming pptNitesh Dubey
 
Queue Data Structure
Queue Data StructureQueue Data Structure
Queue Data StructureZidny Nafan
 
Introduction to OOP concepts
Introduction to OOP conceptsIntroduction to OOP concepts
Introduction to OOP conceptsAhmed Farag
 
Concepts In Object Oriented Programming Languages
Concepts In Object Oriented Programming LanguagesConcepts In Object Oriented Programming Languages
Concepts In Object Oriented Programming Languagesppd1961
 
Hibernate tutorial for beginners
Hibernate tutorial for beginnersHibernate tutorial for beginners
Hibernate tutorial for beginnersRahul Jain
 
Oop c++class(final).ppt
Oop c++class(final).pptOop c++class(final).ppt
Oop c++class(final).pptAlok Kumar
 
Fundamentals of OOP (Object Oriented Programming)
Fundamentals of OOP (Object Oriented Programming)Fundamentals of OOP (Object Oriented Programming)
Fundamentals of OOP (Object Oriented Programming)MD Sulaiman
 

What's hot (20)

Basic Concepts of OOPs (Object Oriented Programming in Java)
Basic Concepts of OOPs (Object Oriented Programming in Java)Basic Concepts of OOPs (Object Oriented Programming in Java)
Basic Concepts of OOPs (Object Oriented Programming in Java)
 
Array of objects.pptx
Array of objects.pptxArray of objects.pptx
Array of objects.pptx
 
Object-oriented concepts
Object-oriented conceptsObject-oriented concepts
Object-oriented concepts
 
Classes and Objects in C#
Classes and Objects in C#Classes and Objects in C#
Classes and Objects in C#
 
Object Oriented Programming Concepts
Object Oriented Programming ConceptsObject Oriented Programming Concepts
Object Oriented Programming Concepts
 
Function in C
Function in CFunction in C
Function in C
 
Dynamic memory allocation in c++
Dynamic memory allocation in c++Dynamic memory allocation in c++
Dynamic memory allocation in c++
 
object oriented Programming ppt
object oriented Programming pptobject oriented Programming ppt
object oriented Programming ppt
 
Queue Data Structure
Queue Data StructureQueue Data Structure
Queue Data Structure
 
Java Collections Framework
Java Collections FrameworkJava Collections Framework
Java Collections Framework
 
C# Encapsulation
C# EncapsulationC# Encapsulation
C# Encapsulation
 
Introduction to OOP concepts
Introduction to OOP conceptsIntroduction to OOP concepts
Introduction to OOP concepts
 
Concepts In Object Oriented Programming Languages
Concepts In Object Oriented Programming LanguagesConcepts In Object Oriented Programming Languages
Concepts In Object Oriented Programming Languages
 
Object oriented programming in python
Object oriented programming in pythonObject oriented programming in python
Object oriented programming in python
 
Hibernate tutorial for beginners
Hibernate tutorial for beginnersHibernate tutorial for beginners
Hibernate tutorial for beginners
 
OOP and FP
OOP and FPOOP and FP
OOP and FP
 
Oop c++class(final).ppt
Oop c++class(final).pptOop c++class(final).ppt
Oop c++class(final).ppt
 
Fundamentals of OOP (Object Oriented Programming)
Fundamentals of OOP (Object Oriented Programming)Fundamentals of OOP (Object Oriented Programming)
Fundamentals of OOP (Object Oriented Programming)
 
Constructor and destructor
Constructor  and  destructor Constructor  and  destructor
Constructor and destructor
 
concept of oops
concept of oopsconcept of oops
concept of oops
 

Similar to Basic oop concepts - C++

Object Oriented Programming With Real-World Scenario
Object Oriented Programming With Real-World ScenarioObject Oriented Programming With Real-World Scenario
Object Oriented Programming With Real-World ScenarioDurgesh Singh
 
Basics of object oriented programming
Basics of object oriented programmingBasics of object oriented programming
Basics of object oriented programmingNitin Kumar Kashyap
 
Intro to oop.pptx
Intro to oop.pptxIntro to oop.pptx
Intro to oop.pptxUmerUmer25
 
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrd
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrdgxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrd
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrdwrushabhsirsat
 
Need of object oriented programming
Need of object oriented programmingNeed of object oriented programming
Need of object oriented programmingAmar Jukuntla
 
CPP-Unit 1.pptx
CPP-Unit 1.pptxCPP-Unit 1.pptx
CPP-Unit 1.pptxYashKoli22
 
Cs690 object oriented_software_engineering_team01_ report
Cs690 object oriented_software_engineering_team01_ reportCs690 object oriented_software_engineering_team01_ report
Cs690 object oriented_software_engineering_team01_ reportKhushboo Wadhwani
 
Oops and c fundamentals
Oops and c fundamentals Oops and c fundamentals
Oops and c fundamentals umesh patil
 
SKILLWISE - OOPS CONCEPT
SKILLWISE - OOPS CONCEPTSKILLWISE - OOPS CONCEPT
SKILLWISE - OOPS CONCEPTSkillwise Group
 
What is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxWhat is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxhreempandya
 
L1-Introduction to OOPs concepts.pdf
L1-Introduction to OOPs concepts.pdfL1-Introduction to OOPs concepts.pdf
L1-Introduction to OOPs concepts.pdfBhanuJatinSingh
 
DOC-20210303-WA0017..pptx,coding stuff in c
DOC-20210303-WA0017..pptx,coding stuff in cDOC-20210303-WA0017..pptx,coding stuff in c
DOC-20210303-WA0017..pptx,coding stuff in cfloraaluoch3
 
SMIRK presentation from ECIL2014
SMIRK presentation from ECIL2014SMIRK presentation from ECIL2014
SMIRK presentation from ECIL2014Marion Kelt
 

Similar to Basic oop concepts - C++ (20)

Object Oriented Programming With Real-World Scenario
Object Oriented Programming With Real-World ScenarioObject Oriented Programming With Real-World Scenario
Object Oriented Programming With Real-World Scenario
 
Basics of object oriented programming
Basics of object oriented programmingBasics of object oriented programming
Basics of object oriented programming
 
Intro to oop.pptx
Intro to oop.pptxIntro to oop.pptx
Intro to oop.pptx
 
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrd
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrdgxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrd
gxhrehsrejhvytftfltyflytdtydtydky5dyrdtrdrdtrd
 
Need of object oriented programming
Need of object oriented programmingNeed of object oriented programming
Need of object oriented programming
 
Unit 2.pptx
Unit 2.pptxUnit 2.pptx
Unit 2.pptx
 
Unit 2.pptx
Unit 2.pptxUnit 2.pptx
Unit 2.pptx
 
CPP-Unit 1.pptx
CPP-Unit 1.pptxCPP-Unit 1.pptx
CPP-Unit 1.pptx
 
Cs690 object oriented_software_engineering_team01_ report
Cs690 object oriented_software_engineering_team01_ reportCs690 object oriented_software_engineering_team01_ report
Cs690 object oriented_software_engineering_team01_ report
 
Oops and c fundamentals
Oops and c fundamentals Oops and c fundamentals
Oops and c fundamentals
 
Benefits of encapsulation
Benefits of encapsulationBenefits of encapsulation
Benefits of encapsulation
 
Chapter 1
Chapter 1Chapter 1
Chapter 1
 
SKILLWISE - OOPS CONCEPT
SKILLWISE - OOPS CONCEPTSKILLWISE - OOPS CONCEPT
SKILLWISE - OOPS CONCEPT
 
What is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptxWhat is OOP_ (Object Oriented Programming) (1).pptx
What is OOP_ (Object Oriented Programming) (1).pptx
 
L1-Introduction to OOPs concepts.pdf
L1-Introduction to OOPs concepts.pdfL1-Introduction to OOPs concepts.pdf
L1-Introduction to OOPs concepts.pdf
 
DOC-20210303-WA0017..pptx,coding stuff in c
DOC-20210303-WA0017..pptx,coding stuff in cDOC-20210303-WA0017..pptx,coding stuff in c
DOC-20210303-WA0017..pptx,coding stuff in c
 
[OOP - Lec 02] Why do we need OOP
[OOP - Lec 02] Why do we need OOP[OOP - Lec 02] Why do we need OOP
[OOP - Lec 02] Why do we need OOP
 
SMIRK presentation from ECIL2014
SMIRK presentation from ECIL2014SMIRK presentation from ECIL2014
SMIRK presentation from ECIL2014
 
Principles of OOPs.pptx
Principles of OOPs.pptxPrinciples of OOPs.pptx
Principles of OOPs.pptx
 
Object oriented programing
Object oriented programingObject oriented programing
Object oriented programing
 

Recently uploaded

Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)Suman Mia
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Dr.Costas Sachpazis
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...Call Girls in Nagpur High Profile
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...ZTE
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxDeepakSakkari2
 
Analog to Digital and Digital to Analog Converter
Analog to Digital and Digital to Analog ConverterAnalog to Digital and Digital to Analog Converter
Analog to Digital and Digital to Analog ConverterAbhinavSharma374939
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )Tsuyoshi Horigome
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxJoão Esperancinha
 
Internship report on mechanical engineering
Internship report on mechanical engineeringInternship report on mechanical engineering
Internship report on mechanical engineeringmalavadedarshan25
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 

Recently uploaded (20)

Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
 
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...
High Profile Call Girls Nashik Megha 7001305949 Independent Escort Service Na...
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...
ZXCTN 5804 / ZTE PTN / ZTE POTN / ZTE 5804 PTN / ZTE POTN 5804 ( 100/200 GE Z...
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptx
 
Analog to Digital and Digital to Analog Converter
Analog to Digital and Digital to Analog ConverterAnalog to Digital and Digital to Analog Converter
Analog to Digital and Digital to Analog Converter
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
 
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptxExploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
 
Internship report on mechanical engineering
Internship report on mechanical engineeringInternship report on mechanical engineering
Internship report on mechanical engineering
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 

Basic oop concepts - C++

  • 1. Click to edit Master title style 1 WITH REAL LIFE EXAMPLES BASIC OOP CONCEPTS By GROUP 2
  • 2. Click to edit Master title style 2 Basic Concepts of Object-Oriented Programming • Classes • Objects • Data Abstraction • Encapsulation • Inheritance • Polymorphism • Dynamic Binding • Message passing 2 Four pillars of OOP concept
  • 3. Click to edit Master title style 3 DATA ABSTRACTION • Data Abstraction is the process of showcasing only the required things to the outside world while hiding the details. • It is the most important pillar in OOPS. • On using the example of mobiles ,  While dialing some methods happen internally which concatenate the numbers and displays it on screen but what it is actually doing is unknown to us.  Clicking on green button actual send signals to calling person's mobile but we are unaware of how it 3
  • 4. Click to edit Master title style 4 • In classes , we can create methods that can be called and used by the users of the class but users will have no idea what these methods do internally. 4
  • 5. Click to edit Master title style 5 ENCAPSULATION • Data binding – binds data variables and functions together in class. • The data can be accessed only by the functions within the class and not by the outside world. • It says how much access must be given to particular details. • This insulation of data is called data hiding/ information hiding. 5
  • 6. Click to edit Master title style 6 Example 1 – Mobile phones 6 • When we switch on a Bluetooth, we can connect to another Bluetooth enabled device, but we don’t have access to other mobile features like dialing number, accessing inbox etc. • This is because Bluetooth has some level of abstraction. Encapsulation and abstraction go hand in hand. • Similarly, when mobile A is connected to mobile B and mobile B is connected to mobile C via Bluetooth , the A can’t connect to C via B.
  • 7. Click to edit Master title style 7 Example 2 – Human body 7 • Different body parts are bound to do different functions. • For example,  Hands - Hold()  Legs - Walk()  Eyes - See()
  • 8. Click to edit Master title style 8 INHERITANCE • Ability to extend the functionality from base entity in new entity belonging to same group. • Helps to reuse functionality. • 5 types: 1. Single level inheritance 2. Multi-level inheritance 3. Hybrid inheritance 4. Hierarchal inheritance 5. Multiple inheritance 8
  • 9. Click to edit Master title style 9 Types Of Inheritance 9 Single level inheritance Multi-level inheritance • Single base class & a single derived class. • More than one single level of derivation.
  • 10. Click to edit Master title style 1010 Hierarchal level inheritance Hybrid inheritance • Multiple derived class would be extended from base class. • Similar to single level inheritance. • Single, Multilevel & hierarchal inheritance all together construct a hybrid inheritance.
  • 11. Click to edit Master title style 11 Multiple inheritance Derived class will ex t en d from mu lt iple base classes. 11
  • 12. Click to edit Master title style 12 POLYMORPHISM • Polymorphism can be defined as the ability of using same name for doing different things. • Many forms of single entity. • Let's consider our example, Samsung mobile has a 5MP camera available i.e. – it is having a functionality of, say, CameraClick(). Now same mobile is having Panorama mode available in camera, so functionality would be same but with mode. This type is said to be Static polymorphism or Compile time polymorphism. 12
  • 13. Click to edit Master title style 13 • Another point where in function ,say, SendMessage() was intended to send message to single person at a time but suppose Nokia had given provision for sending message to a group at once. i.e. - Overriding the functionality to send message to a group. This type is called Dynamic polymorphism or Runtime polymorphism. • For overriding you need to set the method, which can be overridden to virtual & its new implementation should be decorated with override keyword. • By runtime polymorphism, we can point to any 13
  • 14. Click to edit Master title style 14 “ Another trick in software is to avoid rewriting the software by using a piece that's already been written, so called component approach which the latest term for this in the most advanced form is what's called Object Oriented Programming. - Bill Gates 14
  • 15. Click to edit Master title style 15 Thank You