Object Oriented Programming Using C++
Object Oriented Programming Using C++
Course Objectives:
Introduces Object Oriented Programming concepts using the C++ language.
Introduces the principles of data abstraction, inheritance and polymorphism;
Introduces the principles of virtual functions and polymorphism
Introduces handling formatted I/O and unformatted I/O
Introduces exception handling
Course Outcomes:
Able to develop programs with reusability
Develop programs for file handling
Handle exceptions in programming
Develop applications for a range of problems using object-oriented programming techniques
UNIT - I
Object-Oriented Thinking: Different paradigms for problem solving, need for OOP paradigm,
differences between OOP and Procedure oriented programming, Overview of OOP concepts-
Abstraction, Encapsulation, Inheritance and Polymorphism.
C++ Basics: Structure of a C++ program, Data types, Declaration of variables, Expressions,
Operators, Operator Precedence, Evaluation of expressions, Type conversions, Pointers, Arrays,
Pointers and Arrays, Strings, Structures, References. Flow control statement- if, switch, while, for, do,
break, continue, goto statements. Functions - Scope of variables, Parameter passing, Default
arguments, inline functions, Recursive functions, Pointers to functions. Dynamic memory allocation
and de-allocation operators-new and delete, Preprocessor directives.
UNIT - II
C++ Classes and Data Abstraction: Class definition, Class structure, Class objects, Class scope,
this pointer, Friends to a class, Static class members, Constant member functions, Constructors and
Destructors, Dynamic creation and destruction of objects, Data abstraction, ADT and information
hiding.
UNIT - III
Inheritance: Defining a class hierarchy, Different forms of inheritance, Defining the Base and Derived
classes, Access to the base class members, Base and Derived class construction, Destructors, Virtual
base class.
Virtual Functions and Polymorphism: Static and Dynamic binding, virtual functions, Dynamic
binding through virtual functions, Virtual function call mechanism, Pure virtual functions, Abstract
classes, Implications of polymorphic use of classes, Virtual destructors.
UNIT - IV
C++ I/O: I/O using C functions, Stream classes hierarchy, Stream I/O, File streams and String
streams, Overloading operators, Error handling during file operations, Formatted I/O.
UNIT - V
Exception Handling: Benefits of exception handling, Throwing an exception, The try block, Catching
an exception, Exception objects, Exception specifications, Stack unwinding, Rethrowing an exception,
Catching all exceptions.
R18 B.TECH. COMPUTER SCIENCE & ENGG.
TEXT BOOKS:
1. The Complete Reference C++, 4th Edition, Herbert Schildt, Tata McGraw Hill.
2. Problem solving with C++: The Object of Programming, 4th Edition, Walter Savitch, Pearson
Education.
REFERENCES:
1. The C++ Programming Language, 3rd Edition, B. Stroutstrup, Pearson Education.
2. OOP in C++, 3rd Edition, T. Gaddis, J. Walters and G. Muganda, Wiley Dream Tech Press.
3. Object Oriented Programming in C++, 3rd Edition, R. Lafore, Galigotia Publications Pvt Ltd.