Develop a program to allocate seats to customers purchasing tickers for a movie theatre.
The movie theatre has 15 seats, arranged in 3 rows of 5
As a Cinnamon Cinemas Movie Theatre Manager
I want to allocate seats to customers
So that I can control reserved seating for the theatre
The requirement to halt on not enough seats available to be allocated needs some clarification.
This could mean the program is halted when a customer requests 3 seats and there are only 2 remaining, or
that booking remains open until the final seats are taken. The program implements the latter for commercial reasons!
Once cloned, the application can be built using the following Maven command:
mvn compile package
The unit tests will be executed as part of the build process which produces a jar file in the tagret directory.
To run the application, from the command line, enter:
java -jar target/cinnamon-cinema-1.0-SNAPSHOT.jar
No user input is required.The output shows each booking request and whether it has been successful until all seats are booked. A list of customers with the seat allocation is then produced.