Question: Hi, i have this code, i need pseudocode for it please. please no handwriting. Thank you. #include void merchandise(int,int,int,int,int,int ); int add (int ); int

Hi, i have this code, i need pseudocode for it please.

please no handwriting.

Thank you.

#include void merchandise(int,int,int,int,int,int ); int add (int ); int del(int); int main() { int Climbing_shoes = 4, Hiking_boots = 9, Running_shoes = 12, Sneakers = 2, Soccer_shoes = 0, Basketball_shoes = 5; int input, choose; char skip;

printf("# # ##### # ##### ###### ## ## ##### "); printf("# # # # # # # # # # # # "); printf("# # # #### # # # # # # # #### "); (this one is welcome ) printf("# # # # # # # # # # # # "); printf("## ## ##### ##### ##### ###### # # ##### ");

while(choose !=4) { printf("+----------+-----------------------------------+-----+ "); printf("| | Nasser World Shoes inventory Shop | | "); printf("+----------+-----------------------------------+-----+ "); printf("| 1) Current merchandise | "); printf("| 2) Add merchandise | "); printf("| 3) Delete merchandise | "); printf("| 4) Exit | "); printf("+----------------------------------------------------+ "); do { printf(" Enter a Number -> "); scanf("%d", &choose); } while (choose < 1 || choose > 4);

if (choose == 1) { merchandise(Climbing_shoes, Hiking_boots, Running_shoes, Sneakers, Soccer_shoes, Basketball_shoes); printf("Enter anything for back to main menu ->"); scanf(" %c", &skip); } else if (choose == 2) { merchandise(Climbing_shoes, Hiking_boots, Running_shoes, Sneakers, Soccer_shoes, Basketball_shoes); do { printf("Enter the type of shoe you want to add it on -> "); scanf("%d", &input); } while (input < 1 || input > 6);

switch (input) { case 1: Climbing_shoes = add(Climbing_shoes); break; case 2: Hiking_boots = add(Hiking_boots); break; case 3: Running_shoes = add(Running_shoes); break; case 4: Sneakers = add(Sneakers); break; case 5: Soccer_shoes = add(Soccer_shoes); break; case 6: Basketball_shoes = add(Basketball_shoes); break; } printf("The adding already done. "); printf("Enter anything for back to main menu ->"); scanf(" %c", &skip); } else if (choose == 3) { merchandise(Climbing_shoes, Hiking_boots, Running_shoes, Sneakers, Soccer_shoes, Basketball_shoes); printf("Enter the type of shoe you want to delete it on -> "); do { scanf("%d", &input); } while (input < 1 || input > 6);

switch (input) { case 1: Climbing_shoes = del(Climbing_shoes); break; case 2: Hiking_boots = del(Hiking_boots); break; case 3: Running_shoes = del(Running_shoes); break; case 4: Sneakers = del(Sneakers); break; case 5: Soccer_shoes = del(Soccer_shoes); break; case 6: Basketball_shoes = del(Basketball_shoes); break; } printf("The deleting already done. "); printf("Enter anything for back to main menu ->"); scanf(" %c", &skip); } } }

void merchandise(int Climbing,int Hiking,int Running,int Sneakers,int Soccer,int Basketball){ printf("+---------------------------------+ "); printf("| The Merchandise | "); printf("+----------------+----------------+ "); printf("| Type | Quantity | "); printf("+----------------+----------------+ "); printf("| 1) Climbing | %d | ",Climbing); printf("| 2) Hiking | %d | ",Hiking); printf("| 3) Running | %d | ",Running); printf("| 4) Sneakers | %d | ",Sneakers); printf("| 5) Soccer | %d | ",Soccer); printf("| 6) Basketball | %d | ",Basketball); printf("+----------------+----------------+ ");

} int add(int qty){ int num; printf("How many item come of this type ->"); scanf("%d",&num); return (qty + num); } int del(int qty){ int num; printf("How many item out of this type ->"); scanf("%d",&num);

return (qty - num); }

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!