I need help with understanding how to initialize a one dimensional array of vending items in a vending machine to sentinel values and also how to read the data into the one dimensional array of vending items. Please help!!
There are no more than 20 diff items in the vending machine!:'(

Potato Chips
12
0.75
Candy Bar
12
0.75
Gum
25
0.60
Cookies
10
1.25
Mints
15
1.00

>>how to initialize a one dimensional array

you can initialize an array at the time it is declared, like this int array[25] = {0}; >>how to read the data into the one dimensional array
use a loop and read each element one at a time. Details should be in your textbook and depends on whether you are writing C or C++ program.