0% found this document useful (0 votes)
13 views2 pages

Chapter 1

The document discusses the differences between procedure oriented and object oriented programming languages, characteristics of object oriented languages, advantages and applications of C++, and provides an example structure of a basic C++ program. Procedure oriented languages follow a top-down approach and focus on procedures while object oriented languages follow a bottom-up approach and focus on data. C++ supports features like classes, inheritance and polymorphism and has advantages like flexibility, portability and extensibility. It provides a standard template library and rich built-in functions.

Uploaded by

wednesday262626
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views2 pages

Chapter 1

The document discusses the differences between procedure oriented and object oriented programming languages, characteristics of object oriented languages, advantages and applications of C++, and provides an example structure of a basic C++ program. Procedure oriented languages follow a top-down approach and focus on procedures while object oriented languages follow a bottom-up approach and focus on data. C++ supports features like classes, inheritance and polymorphism and has advantages like flexibility, portability and extensibility. It provides a standard template library and rich built-in functions.

Uploaded by

wednesday262626
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

Chapter 1 :

1. Explain the difference between procedure oriented and object oriented


programming language.
->>>>Focus/Emphasis:
 POP: Focuses on procedures or algorithms .
 OOP: Focuses on Data.
Approach:
 POP: Follows top down approach in program design.
 OOP: Follows Bottom up approach in program design.
Division:
 POP: Large programs are divided into functions.
 OOP: Large programs are divided into Objects(entities).
Examples:
 POP: BASIC,C,COBOL,Pascal,Fortran
 OOP: C++,C#, Java and Python.
Reusability:
 POP: Limited code reuse.
 OOP: freely code reuse.

Security:
 POP: Data is less Secure.
 OOP: Data is More Secure and hidden.
Memory/storage space :
 POP: its memory requirement is less.
 OOP: its memory requirement is high.

2. Discuss the characteristics of Object Oriented languages.


->>>Object-Oriented Programming (OOP) is a programming paradigm that
organizes code into objects, which are instances of classes, and allows for
the modeling of real-world entities and their interactions.

 Applications of OOPs.
 Real time systems
 Simulation and modeling
 Object oriented database
 Hypertext,Hypermedia and expertext
 AI and Expert system.
 Neural networks and parallel programming
 CIM/CAD/CAM systems.

3. Write the advantages / features and applications of C++.


->>>Object-Oriented Programming (OOP):C++ supports
object-oriented programming, feature includes classes, objects,
inheritance, polymorphism, and encapsulation.
 Simple: C++ is one of the most simple languages for
programmers to learn and use. It is also easy to understand and
learn as it originated from the C.

Portable:C++ is considered a machine-independent or portable language. it can be


run on
different machines.

 Flexibility: C++ supports both procedural and object-oriented programming


paradigms,
providing developers with flexibility.

 Extensible:C++ programs can easily be extended as it is very easy to add new


features into
the existing program.

 Standard Template Library (STL): C++ includes a powerful STL that provides a
collection of
template classes and functions, offering generic algorithms, containers, and
iterators .

 Rich Library:C++ provides a lot of inbuilt functions that make the development
fast.
Following are the libraries used in C++ programming are:<iostream>,
<cmath> ,<cstdlib>
,<fstream>.

 Structured programming language:C++ is a structured programming language. In this


we can divide the program into several parts using functions.

 Case Sensitive:C++ is a case-sensitive programming language. For example, cin is


used to
take input from the outputstream. But if the “Cin” won’t work.

4. Describe a structure of C++ program with example.


->>#include <iostream> // Preprocessor Directives &headerfile
using namespace std; // Namespace Declaration:
int main( ) // Main Function:
{

// Function Body:
cout << "Hello, World!" << endl;
return 0; // Return 0 to indicate successful execution

}
Output:
Hello, World!

You might also like