Question: Hello! I am needing some help with this project. I do not know where to begin. It is in Java. (1) Prompt the user to
Hello! I am needing some help with this project. I do not know where to begin. It is in Java.
(1) Prompt the user to input a positive number - the number of gift items - must be positive or print error and re-enter.
sample output:
Input number of gift items: -2
ERROR: number of items must be greater than zero.
Input number of gift items: 0
ERROR: number of items must be greater than zero.
Input number of gift items: 3
(2) Create an array of gift item names and gift item quantity. (3) Ask the user to input the name of each gift item and store into an array.
sample output:
Input name of gift item 1: ham
Input name of gift item 2: egg
Input name of gift item 3: cheese
Thank you so much for your help in advance!
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
