This is for a hw assignment i am having trouble with. I need to:
Use a single-subscripted array to represent a seating chart on a plane. Initialize all the elements of the array to 0 to indicate that all the seats are empty.
This is where i am having trouble:
As each seat is assigned, set the corresponding elements of the array to 1 to indicate that the seat in taken. The program should never assign a seat twice.
Do i increment the array? I know this is basic stuff but i am very new to it. Thanks
Use a single-subscripted array to represent a seating chart on a plane. Initialize all the elements of the array to 0 to indicate that all the seats are empty.
This is where i am having trouble:
As each seat is assigned, set the corresponding elements of the array to 1 to indicate that the seat in taken. The program should never assign a seat twice.
Do i increment the array? I know this is basic stuff but i am very new to it. Thanks