Professional Documents
Culture Documents
PROGRAMMING
Steve Clar
CHAPTER 1
THE BIG PICTURE
• PROCEDURAL VERSUS OBJECT-ORIENTED LANGUAGES
• FEATURES OF OBJECT-ORIENTED LANGUAGES
• INTRODUCTION TO CLASSES AND OBJECTS
• INTRODUCTION TO INHERITANCE
• C++ AND C
WHY DO WE NEED
OBJECT-ORIENTED
PROGRAMMI
NG?
PROCEDURAL LANGUAGES
Pascal, C, BASIC, Fortran, and similar languages are procedural languages.
Dividing a program into functions and modules is one of the cornerstone of structured
programming , the somewhat loosely defined discipline that has influenced programming
organization for more than a decade.
PROBLEMS WITH STRUCTURED
PROGRAMMING
As programs grow ever larger and more complex, even the structured programming
called object.
An object’s functions, called member functions in C++, typically provide the only way to
Data Encapsulation and Data Hiding are the key terms in the description of object-oriented
languages.
OOP: AN APPROACH TO
ORGANIZATION
Object-oriented programming is not primarily concerned with the details of program
operation. Instead, it deals with the overall organization of the program
CHARACTERISTICS OF
OBJECT-ORIENTED
PROGRAMMING
• OBJECTS
• CLASSES
• INHERITANCE
• REUSABILITY
OBJECT
Programming Constructs
Customized Array
Stack
Linked List
Binary Trees
Physical Objects
INHERITANCE
Analogous to using functions to simplify a traditional procedural program.
C++ AND C
C++ is derived from the C language.
SUMMARY
OOP is a way of organizing programs.