Click here to Skip to main content
15,916,463 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: INTRODUCTION Pin
Hamid_RT25-Apr-08 9:15
Hamid_RT25-Apr-08 9:15 
GeneralRe: INTRODUCTION Pin
tuneroz25-Apr-08 9:26
tuneroz25-Apr-08 9:26 
GeneralRe: INTRODUCTION Pin
Hamid_RT25-Apr-08 20:41
Hamid_RT25-Apr-08 20:41 
GeneralRe: INTRODUCTION Pin
CPallini25-Apr-08 9:56
mveCPallini25-Apr-08 9:56 
GeneralRe: INTRODUCTION Pin
Hamid_RT25-Apr-08 20:38
Hamid_RT25-Apr-08 20:38 
GeneralRe: INTRODUCTION Pin
CPallini25-Apr-08 22:47
mveCPallini25-Apr-08 22:47 
GeneralRe: INTRODUCTION Pin
Hamid_RT26-Apr-08 4:18
Hamid_RT26-Apr-08 4:18 
QuestionRequired C++ source code for below question Pin
ChayaMandini25-Apr-08 6:49
ChayaMandini25-Apr-08 6:49 
Hi, I have below a question on programming in C++ which seems complicated to me.Please help asap.

A shop wishes to have a computerised system for its cashier. The program should help the
cashier to calculate the total payment required to be performed by each customer. It also should
be able to keep record of the number of customers for a day, calculate the total income of the
shop for the day as well as the average amount spent by a customer. You can assume that for
each customer coming to the counter, the cashier can find out how many different items he/she
has purchased before inputting the details of the purchase. However, the cashier does not
know, in the morning, the number of customers that are likely to visit the shop for the day.
Write a program that can perform the required work for the cashier. Your program should have
the following features:
• It allows the input of a number n, representing the number of items to be purchased by the
customer.
• It then allows the input of n pairs of values representing the quantity and price per unit for
each of the n items. For each item, the computer needs to display the total resulting amount.
• It Calculates and displays the total payment to be performed by the customer.
After having displayed the required values for a customer the program should ask the user
whether to input for a new customer. If the answer is yes, the program should repeat the
above steps. Otherwise, it should display the following values
• The number of customers.
• The total amount paid by all customers
• The average amount spent by a customer.
Your program should perform the following validations:
• Quantity of an items should be in the range 1..10.
• Price of an item should be greater than 0 and not more than 100.00.
For input, the computer should give the user the item number and the user should enter the
values of quantity and price. The computer should immediately display the total amount to be
paid for that item. A typical user screen, for one customer, should look as
below:
Item Quantity Price Per Unit Total Cost
1 2 20.00 40.00
2 3 25.50 76.50
3 1 30.00 30.00
Total 146.50
You may use an array to store the data pertaining to the different customers.
GeneralRe: Required C++ source code for below question Pin
CPallini25-Apr-08 6:58
mveCPallini25-Apr-08 6:58 
GeneralRe: Required C++ source code for below question Pin
Maximilien25-Apr-08 7:08
Maximilien25-Apr-08 7:08 
GeneralRe: Required C++ source code for below question Pin
Hamid_RT25-Apr-08 7:11
Hamid_RT25-Apr-08 7:11 
GeneralRe: Required C++ source code for below question Pin
Michael Schubert25-Apr-08 7:28
Michael Schubert25-Apr-08 7:28 
GeneralRe: Required C++ source code for below question Pin
Joan M25-Apr-08 8:47
professionalJoan M25-Apr-08 8:47 
GeneralRe: Required C++ source code for below question Pin
Prasann Mayekar26-Apr-08 0:28
Prasann Mayekar26-Apr-08 0:28 
GeneralRe: Required C++ source code for below question Pin
enhzflep27-Apr-08 1:09
enhzflep27-Apr-08 1:09 
GeneralRe: Required C++ source code for below question Pin
David Crow27-Apr-08 15:17
David Crow27-Apr-08 15:17 
GeneralChanging colour for CStatic Pin
prithaa25-Apr-08 3:58
prithaa25-Apr-08 3:58 
GeneralRe: Changing colour for CStatic Pin
David Crow25-Apr-08 4:41
David Crow25-Apr-08 4:41 
GeneralRe: Changing colour for CStatic Pin
Mark Salsbery25-Apr-08 5:53
Mark Salsbery25-Apr-08 5:53 
GeneralRe: Changing colour for CStatic Pin
prithaa25-Apr-08 19:36
prithaa25-Apr-08 19:36 
QuestionRe: Changing colour for CStatic Pin
Rajkumar R25-Apr-08 23:38
Rajkumar R25-Apr-08 23:38 
QuestionRe: Changing colour for CStatic Pin
David Crow27-Apr-08 15:15
David Crow27-Apr-08 15:15 
GeneralRe: Changing colour for CStatic Pin
prithaa28-Apr-08 0:30
prithaa28-Apr-08 0:30 
GeneralRe: Changing colour for CStatic Pin
David Crow28-Apr-08 4:04
David Crow28-Apr-08 4:04 
Generalhi i want to generate binary states in sorting order in terms of no of 1's plz help Pin
Member 465568525-Apr-08 3:39
Member 465568525-Apr-08 3:39 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.