The following is a program that simulates a pizza delivery menu. A user can choose to buy
Question:
The following is a program that simulates a pizza delivery menu. A user can choose to buy pizza, breadsticks, pasta, OR wings. Fill in the missing pieces of the program so that the user can accurately input how many of their selected items they wish to buy and print the final cost at the end.
#include <stdio.h>
#define PIZZA 12.50
#define BREAD 3.00
#define WINGS 8.50
#define BREAD_STICKS 5.00
int main){
int selection, num_pizza=0, num_bread=0;
int num_pasta=0, num_wings=0;
double cost;
printf(“Welcome to the Pizza Corner!\n”);
printf(“What would you like to do?\n”);
printf(“\t 1 – Buy Pizza.\n”);
printf(“\t 2 – Buy Bread.\n”);
printf(“\t 3 – Buy Wings.\n”);
scanf(“%d”, &selection);
switch ( )
case ______:
break;
case ______:
break;
case _______:
break;
default: ______________
break;
}
cost =
printf(“Your total cost is _____.\n”, cost);
return 0;
}
Principles of Auditing and Other Assurance Services
ISBN: 978-0078025617
19th edition
Authors: Ray Whittington, Kurt Pany