Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please include a DETAILED documentation so i can understand it better :) The purpose of this assignment is to learn how to work with iteration

image text in transcribed

please include a DETAILED documentation so i can understand it better :)

The purpose of this assignment is to learn how to work with iteration and constants Additionally, you get more practice on how to write all of your own code and Javadoc comments Problem Description This problem is inspired by the book's Problem P6.10 on page 304. You are to write an application to presell a limited number of movie tickets. The simple user interface will be contained in Main java and the object to implement this is referred to as TicketSeller and consists of only the following public methods: public TicketSeller(int initialTicketAllotment) -Specify the number of tickets you want to sell. public int requestTickets(int ticketRequest) Requests ticketRequest number of tickets. Returns TicketSeller.TOO_MANY_TICKETS_REQUESTED if there are more than TicketSeller.MAXIMUM_TICKETS ALLOWED. Note that one of these constants is private and one is public. Which one needs to be exposed to the user? public int getNumberOfBuyerso - Tracks number of ticket buyers. You only count buyers who have fulfilled a request. Errors don't count. Your Main,java should contain code to test your TicketSeller object. Note Your requests for tickets will always be positive integers. You can pre-sell O tickets. Note that all requests but a request for 0 tickets are requesting too many tickets. . You should use constants for TicketSeller.TOO MANY TICKETS_REQUESTED and TicketSeller.MAXIMUM TICKETS_ALLOWED not an enumerated type

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Building The Data Warehouse

Authors: W. H. Inmon

4th Edition

0764599445, 978-0764599446

More Books

Students also viewed these Databases questions