Cs593 Lab Assignments
Cs593 Lab Assignments
(2012-2013)
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING B. P. PODDAR INSTITUTE OF MANAGEMENT & TECHNOLOGY
WBUT SYLLABUS
Introduction of UNIX/Linux Operating System which includes preliminary commands, startup & shutdown methodology, file handling as well as introduction to editors like Vi editor, introduction to GNU C & C++ compiler, as well as introduction to GNU & GDB script. [4P] Introduction to C++, basic loop control, executing programs, writing functions, selection statements, review of functions and parameters, command line arguments, recursion, I/O streams, arraysand string manipulation, pointers, structures & unions. [6P]
Object-Oriented Programming in C++, fundamentals of classes, constructors-destructors. Dealing with member functions, operator overloading and polymorphism (both static & dynamic).[6P] Dealing with inheritance, derived class handling, abstract class, virtual class, overriding, template class, name-space & exception handling.[4P] Dynamic memory allocation, implementation of Linked Lists, using C++.[4P]
Data Hiding
ASSIGNMENT 03: Create a class called carpart that has int member data for car id, int member data for charge/hour and float member data for time. Set the data and show the charges and parked hours of corresponding car id. Make two member functions for setting and showing the data. Member function should be called from other functions. ASSIGNMENT 04: Let us consider a shopping list of items for which we place an order with a dealer every month.The list includes details such as the code number and price of each item.We would like to perform operations such as adding an item to the list, deleting an itam from the list and printing the total value of the order.
Constructor Overloading
ASSIGNMENT 12: Create a class called complex that has two floating point data members x and y. Write a C++ program to add two complex numbers by using multiple constructors in the class complex.
Copy constructor
ASSIGNMENT 14: Write a C++ program to illustrate the concept of Copy Constructors.
this Pointer
ASSIGNMENT 16: Write a C++ program to illustrate the working of this pointer.
Destructor
ASSIGNMENT 17: Write a C++ program to implement the concept of Destructor.
Multiple inheritance
ASSIGNMENT 20: Consider a publishing company that publishes and markets books, whose activities are shown in Figure below. Create a class publication that stores the title (string) and price (float) of a publication. Create another class sales that holds an array of three float's so that it can record the sales of a particular publication for the last three months. From these two classes, derive a new class called book that hold pages of integer type. Each of these classes should have the member functions getdata() and display().
From the publication and sales classes, derive the tape class, which adds playing time in minutes (type float). Create another class pamphlet from publication, which has no features of its own. Derive a class notice from pamphlet class having data members char whom[20] and member functions getdata() and putdata().
Hybrid Inheritance
ASSIGNMENT 21: Write a C++ program to implement hybrid inheritance.
Runtime Polymorphism
ASSIGNMENT 23: Create three classes media(base class), book(publicly derived from class media) tape(publicly derived from class media).Write a C++ program to display the details of book(title, pages and price) and tape(title, play time and price) by using the concept of Runtime Polymorphism. The details of book (title, pages and price) and tape (title, play time and price) will be entered through keyboard in main () function.
INNOVATIVE PROGRAMS
1. MINI PROJECT 01: banking-system-project using C++ 2. MINI PROJECT 02: library-management-system-project using C++ 3. MINI PROJECT 03: Student Record Systemproject using C++