Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
14 views

Object Oriented Programming Lab 0 0 3 2

The document describes 10 programming assignments for an Object Oriented Programming lab: 1. Design classes with static members, methods with default arguments, and friend functions. 2. Implement a complex number class with operator overloading and type conversions. 3. Implement a Matrix class with dynamic memory allocation and necessary methods like constructors and overloaded assignment.

Uploaded by

Anjana Sudhir
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views

Object Oriented Programming Lab 0 0 3 2

The document describes 10 programming assignments for an Object Oriented Programming lab: 1. Design classes with static members, methods with default arguments, and friend functions. 2. Implement a complex number class with operator overloading and type conversions. 3. Implement a Matrix class with dynamic memory allocation and necessary methods like constructors and overloaded assignment.

Uploaded by

Anjana Sudhir
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

141353

OBJECT ORIENTED PROGRAMMING LAB (Common to CSE & IT)

0 0 3 2

1. Design C++ classes with static members, methods with default arguments, friend functions. (For example, design matrix and vector classes with static allocation, and a friend function to do matrix-vector multiplication) 2. Implement complex number class with necessary operator overloadings and type conversions such as integer to complex, double to complex, complex to double etc. 3. Implement Matrix class with dynamic memory allocation and necessary methods. Give proper constructor, destructor, copy constructor, and overloading of assignment operator. 4. Overload the new and delete operators to provide custom dynamic allocation of memory. 5. Develop a template of linked-list class and its methods. 6. Develop templates of standard sorting algorithms such as bubble sort, insertion sort, merge sort, and quick sort. 7. Design stack and queue classes with necessary exception handling. 8. Define Point class and an Arc class. Define a Graph class which represents graph as a collection of Point objects and Arc objects. Write a method to find a minimum cost spanning tree in a graph. 9. Develop with suitable hierarchy, classes for Point, Shape, Rectangle, Square, Circle, Ellipse, Triangle, Polygon, etc. Design a simple test application to demonstrate dynamic polymorphism and RTTI. 10. Write a C++ program that randomly generates complex numbers (use previously designed Complex class) and writes them two per line in a file along with an operator (+, -, *, or /). The numbers are written to file in the format (a + ib). Write another program to read one line at a time from this file, perform the corresponding operation on the two complex numbers read, and write the result to another file (one per line).

You might also like