Start
Void welcome()
int input
char character
“Welcome to JCOles’s Store!
Press Y to continue or press
N to exit”
“Enter your input[Y/N]”
character
Switch (character) goto
input
case ‘Y’ ||
case ‘y’ A
case ‘N’ ||
case ‘n’
“Goodbye! Have a
nice day!”
B
“You’ve entered a
default
wrong input”
A
Void menu()
int order, quantity
char choice, character, receipt
float pay, balance
const float set1=60.00, set2=45.00,
set3=150.00, set4=75.00
“Set A to D”
goto
choose
“What do you like? Choose a set: “
choice
Switch (choice)
“You pick Set A
+ ------------- -Set A------------- +
case ‘A’ || | Food: Puto with Dinuguan |
case ‘a’ “Quantity:” quantity
| Drink : Pepsi |
| Price : Php 60.00 |
+ ----------------------------------- +”
“Your payment “Your total cost
set1*quantity
please: Php” is: Php”
F
If(pay>=(set1* “Your payment is
Pay quantity)) not enough”
“Your balance is:
Balance=pay-(set1*quantity)
Php”
“Here’s your while(pay<(set
receipt:” 1*quantity))
Balance
receipt C
“You pick Set B
case ‘B’ || + ----------Set B----------- +
case ‘b’ “Quantity:” quantity | Food : Leche Flan |
| Drink : Coca Cola |
| Price : Php 45.00 |
+ ---------------------------- +
“Your payment “Your total cost
set2*quantity
please: Php” is: Php”
F
If(pay>=(set2* “Your payment is
Pay quantity)) not enough”
T
“Your balance is:
Balance=pay-(set2*quantity)
Php”
“Here’s your while(pay<(set
2*quantity)) Balance
receipt:”
receipt C
“You pick Set C
+ ---------------Set C------------- +
case ‘C’ ||
“Quantity:” quantity | Food : Chicken Lauriat |
case ‘c’ | Drink : Sprite |
| Price : Php 150.00 |
+ ---------------------------------- +
“Your payment “Your total cost
set3*quantity
please: Php” is: Php”
F
If(pay>=(set3* “Your payment is
Pay quantity)) not enough”
“Your balance is:
Balance=pay-(set3*quantity)
Php”
“Here’s your while(pay<(set
receipt:” 3*quantity))
Balance
receipt C
“You pick Set D
case ‘D’ || + ---------------Set D------------- +
“Quantity:” quantity | Food : Tapsilog |
case ‘d’
| Drink : 7up |
| Price : Php 75.00 |
+ ---------------------------------- +
“Your payment “Your total cost
set4*quantity
please: Php” is: Php”
F
If(pay>=(set4* “Your payment is
Pay quantity)) not enough”
“Your balance is:
Balance=pay-(set4*quantity)
Php”
“Here’s your while(pay<(set
4*quantity)) Balance
receipt:”
receipt C
default “Set not
Available”
C
Void inmenu()
Int input
“Menu:
1. Order again
2. Exit
Enter choice:”
input
Switch (input)
case 1 A
+ --------------------------------------- +
case 2 | Thank you! Please come again |
+ --------------------------------------- +
B
default “You’ve entered a
wrong input”
C
Stop