I just can't seem to understand when i am suppose to put Accept outside the LOOP and when i'm suppose to Accept inside the LOOP at the beginning. Can anyone please make me understand??

Recommended Answers

All 4 Replies

Thanks for the reference it was really helpful.

Today i was given a problem by a close friend to solve but no matter how hard i try i can't get it to run.

A program is required for calculating the amount to be paid by families attending the final of the rugby World Cup in New Zealand.
The family members can only be classified as either Adults or Children. The Adult pays the full price of the ticket while Children pay only half the price of the ticket.
At the ticket counter, the family can pay either by cash (ch) or by credit card (cc).
There are three different types of tickets namely A, B, or C and a family can only buy a certain type as shown on the table below:

Ticket Type Price Per Ticket
A R150
B R200
C R300

You are required to write a VB program that shall accept the ticket type (only A or B or C), the number of adults, the number of children, and the mode of payment (ch or cc) for many families until a negative number is input for the number of adults. New Zealand uses the Dollar as currency: 1 dollar = R4.70.
When there is no more input, the program must calculate and display (with meaningful message) on the screen the following:

• The number of families that bought tickets
• The number of families who paid using a credit card
• The Total amount of money paid by all families in cash (in Rands)
• The total amount of money paid by all families (in cash and by credit card)(in Dollars)

Some help????

Is this an excersize for loops?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.