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

Object-Oriented Programming Experiments

The document outlines a list of experiments for the Object Oriented Programming Lab (BCA-306P) at the Lloyd Institute of Management & Technology. It includes various programming tasks such as creating classes, demonstrating inheritance, operator overloading, and exception handling. The experiments aim to enhance students' understanding of object-oriented programming concepts through practical applications.

Uploaded by

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

Object-Oriented Programming Experiments

The document outlines a list of experiments for the Object Oriented Programming Lab (BCA-306P) at the Lloyd Institute of Management & Technology. It includes various programming tasks such as creating classes, demonstrating inheritance, operator overloading, and exception handling. The experiments aim to enhance students' understanding of object-oriented programming concepts through practical applications.

Uploaded by

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

Lloyd Institute of Management & Technology, Greater Noida

Plot No.3, Knowledge Park 2, Greater Noida, Uttar Pardesh 201306


Department of Bachelor of Computer Application

Object Oriented Programming Lab (BCA-306P)


List of Experiments
Exp. No. Experiment Name

1. Write a program to input two numbers using cin and display their sum, difference, multiplication, and
division.

2. Write a program to use new to create a variable in memory and use delete to free that memory.

3. Write a program to compare C-style programming and OOP-style programming by calculating the area of
a circle using:
a) a simple function (C style)
b) a class (C++ style)
4. Create a class Student with name, roll number, and marks. Add functions to input and display details.

5. Show Encapsulation using private data members and public getter/setter functions.

6. Create a Rectangle class with a constructor to set length and width and a function to calculate area.

7. Demonstrate Constructor Overloading using a Complex number class and also use the destructor to print
a message when the object is destroyed.

8. Dynamically create an integer array using new[], take input, display values, and free memory using
delete[].

9. Demonstrate Single Inheritance & Multilevel Inheritance with example.

10. Demonstrate Multiple Inheritance using Result, Test, and Sports classes.

11. Demonstrate Method Overloading using multiple functions with the same name.

12. Overload the + operator to add two complex numbers.

13. Demonstrate Runtime Polymorphism using virtual functions and base class pointers.

14. Create a Function Template to find the maximum of two values.

15. Create a Class Template Calculator for addition, subtraction, multiplication, and division.

16. Demonstrate Runtime Polymorphism to calculate area of shapes (circle, rectangle, triangle) and also add
Function Overriding.

17. Write and read text from a file named [Link].

18. Write details of 5 students into a file and display them.

19. Handle divide-by-zero using try, catch, and throw.


20. Create a BankAccount class that throws an exception when withdrawal amount is more than balance.

21. Library Book Management System using class teplates, file handling, and exceptions.

You might also like