Question: Please answer the section that says //FIX ME:// for the Seat reservation program. Modify the program to have a command to delete a reservation. Modify

Please answer the section that says //FIX ME:// for the Seat reservation program.

Modify the program to have a command to delete a reservation.

Modify the program to define and use a method public static void makeSeatReservations(ArrayList seats, Scanner scnr) so that the program's main() is cleaner.

Please answer the section that says //FIX ME:// for the Seat reservationprogram. Modify the program to have a command to delete a reservation.

1 import java.util.ArrayList; 2 import java.util.Scanner; 4 public class SeatReservation solok Methods for ArrayList of Seat objects olok/ public static void makeSeatsEmpty(ArrayList seats) t int i; for (i 0; i seats) t int i; for (i : 0; seats. size(); ++1) { System.out.print(i+ ": "); seats.get(i).print); public static void addSeats(ArrayList seats, int numSeats) int i; 23 24 25 26 27 28 29 30 seats.add (new Seat)); solok End methods for ArrayList of Seat objects olok/ public static void main (String [1 args) Scanner scnr new Scanner(System.in); String usrInput; String firstName, lastName; int amountPaid; int seatNumber; Seat newSeat; ArrayListSeat auseats new ArrayListSeat>(); 32 35 36 37 38 39 40 41 usrInput "; // Add 5 seat objects to ArrayList addSeats(allSeats, 5); // Make all seats empty makeSeatsEmpty(allSeats); 45

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!