Basic C++ program
- Write a C++ program that will ask a distance in inches and display it in feet, and meter.
- Create a class called Book that contains data members such as bookno (an int), title(array of char),author (array of char) and price (type float). Include a member function called getdata() to getbook details from the user, and another function called putdata() to display all the details. Finally create a member function sortByTitle(), that will sort the data for all the items in the ascending order of book title. Write a menu driven program to exercise this class. Invite the user to input data for up to 5-10 Books.
- Create a class called Emp that contains data members such as emp code,emp name and salary.Geneate menu driven program and perform following task
- Insert Emp Data
- View Emp Data
- Sort emp data based on name
- Sort Emp data based on salary
- Exit
- [View Code]
Leave a Reply