hi i need help creating a program using arrays. this is what is assigned and i cant figure much of it out ! please help!
The single field (instance variable) for this class is a array of type char named seats[] with 10 elements. The first five elements (0 to 4) in the array store information about seats in First Class; the last five elements (5 to 9) are for Coach. A value of 'O' for any element means that the seat is unassigned; a value of 'X' for a seat element means that it has been reserved.
The seats[] array field should be declared with no initial values assigned and instantiated in the constructor method. In the constructor then use a loop (of any type, although if you choose a loop structure using the array's index, use the array's length property as the terminating value for the loop) that assigns the character value 'O' to all ten elements (meaning that the seats are unassigned). At the conclusion of the constructor, call the displaySeats() method (see below) to show the plane's reservation status.
i know how to create the array object for seats but i got stuck at the constructor..can anybody help me!