Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
CS201 Introduction to Programming Assignment No. 05 Semester Spring June 2012
#1
Assignment No. 05
Semester: Spring 2012
CS201 Introduction to Programming



Problem Statement: Customer Bill Information

Write a program that takes customer’s information from user i.e. name, ID and spending and displays the same customer information plus total bill on the screen. You will use the same Customer class implemented in Assignment#3. You need to overload stream insertion << and stream extraction >> operators for the Customer class.

Detailed Description:

 Use the same Customer class you implemented in Assignment#3.
 This time you don’t need the friend function for calculation of total bill according to spending.
 You can modify the class (add or delete some functions) as per program requirement.
 You will overload extraction operator >> for getting input for an object of Customer class.
 You will also overload insertion operator << for displaying the customer information on screen.
 On calling extraction operator in main() e.g. cin>>obj where obj is an object of Customer class, information about customer name, ID and spending should be taken from the user.
 Take a look at the sample output for better understanding.











 On calling insertion operator in main() e.g. cout<<obj, the output in the following format should be displayed.





 You must use the formatting manipulators setw() and setfill() for formatting the text as shown in the output.
 All the formatting of text should be implemented inside overloaded function for extraction operator <<
 The main() function of your solution should contain only these instructions

Customer obj;
cin >> obj;
cout << obj;
system(“pause”);


Attached Files
.doc   Spring 2012_CS201_5.doc (Size: 221.5 KB / Downloads: 90)

0300-9520262
Get solution in 24 hour
|cpmputer & internetConfusedmileys81:[SIZE="4"][SIZE="3"]....[/SIZE][/SIZE]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  CS301 Assignment # 4 Due Date: 02-Feb-2016 Vuhelper 0 2,322 02-03-2016, 05:38 PM
Last Post: Vuhelper
  CS703 – Advanced Operating Systems Assignment No.3 solution January 2016 Vuhelper 0 5,908 01-23-2016, 09:58 PM
Last Post: Vuhelper
  CS601 Data Communication Assignment No. 03 Solution 23rd January 2016 Vuhelper 1 1,928 01-23-2016, 06:09 PM
Last Post: Vuhelper
  CS403 Assignment No. 03 Solution 23rd January 2016 Vuhelper 2 1,165 01-23-2016, 03:18 PM
Last Post: Vuhelper
  CS506 Web Design and Development Assignment no 3 Solution 3rd January 2016 Vuhelper 0 2,242 01-23-2016, 03:16 PM
Last Post: Vuhelper
  CS724 Software Process Improvement Assignment No 01 Solution 20th January 2016 Vuhelper 0 1,967 01-20-2016, 06:26 PM
Last Post: Vuhelper
  CS711 Software Design Assignment No 01 Solution Due Date Feb 12, 2016 Vuhelper 0 1,664 01-20-2016, 06:24 PM
Last Post: Vuhelper
  CS709 Formal Methods for Software Engineering Assignment No 01 Solution January 2016 Vuhelper 0 1,800 01-20-2016, 06:22 PM
Last Post: Vuhelper
  cs703 assignment no 3 Solution 20th January 2016 Vuhelper 0 1,701 01-20-2016, 06:20 PM
Last Post: Vuhelper
  CS704 Assignment No. 01 Solution January 2016 Vuhelper 0 4,797 01-20-2016, 06:19 PM
Last Post: Vuhelper

Forum Jump:


Users browsing this thread: 1 Guest(s)