0% found this document useful (0 votes)
5 views

list of oops programs

Oops

Uploaded by

ridervinayyy
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

list of oops programs

Oops

Uploaded by

ridervinayyy
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

1. Write a C++ program to calculate average marks scored by a student for 3 subjects.

2. Write a C++ program to find the area and perimeter of a circle and rectangle.

3. Write a C++ program to swap two numbers.

4. Write a C++ program to generate Fibonacci series.

5. Write a C++ program to perform string manipulation.

6. Find the length of a string. Compare two strings, Concatenate two strings, Reverse a
string, copy a string to another location.

7. Write a C++ program to generate Prime numbers between 1 and 50.

8. Write a C++ program to perform matrix addition and multiplication.

9. Write a C++ program to overload a function to calculate volume of cube, cylinder and
rectangular box.

10. Write a C++ program to create a function template to swap two numbers.

11. Write a code for swapping of two characters through swap function which shows the
functionality of call by reference?

12. Write a program to the functionality of inline function?

13. Write a program to show the use of friend function?

14. Create a student class to read and display data of five students, which has roll number
and name of student as data member and read and display as member functions.

15. Write a C++ program to manipulate the class account using classes and function. A
user should be able to perform the following functions. a. Deposit money. b.
Withdraw money, c. Calculate the interest d. Check the total balance in his account.

16. Create a distance class to show the addition of two distance objects. Class contains
two data members feet and inch. Create addition class to add two objects of distance
class.

17. Write a C++ program to implement Account class with the data members account
number, A/c holder’s Name and Balance, and member function for following
operations use constructors to initialize data members..
a. To Deposit amount
b. To Withdraw amount
c. To Transfer amount from one A/c to another.
18. Write a C++ program to create a time class. Implement various constructors for time
class. A member function should display the object of time in hour : min : sec format
and a member function to add two objects of time class.

19. Write a C++ program to overload -- operator?

20. Create a date class which has data members day, month, and year. Overload operator
‘++’ to increase date by one and create necessary constructors to initialize members.

21. Write a C++ program to overload ‘+’ and ‘-‘, operators for Complex class i.e. these
operators can be used to add and subtract two objects (complex numbers) of complex
class.

22. Overload ‘+’ for concatenation of two strings?

23. Write a C++ program to create a class called STUDENT with data members roll
number, Name and Age. Using inheritance, create the classes UGSTUDENT and
PGSTUDENT having fields as Semester, Fees and Stipend. Enter display the data for
at least 5 students.

24. Explain the utility of virtual function through a C++ program?

25. Write a C++ program to implement the following inheritance.

Student

Internal Exam External Exam

Result

You might also like