Question: i want write code for this please write the answer in java Create a movie class. The movie class has id, name, tour, price properties.

i want write code for this

please write the answer in java

Create a movie class. The movie class has id, name, tour, price properties. Create a user class. User class has name, age and balance properties. Create a cinema class. Cinema class name and movieList (ArrayList accepting objects of Movie class type) properties. Cinema class has the Add movie method. This method takes an object of type Movie class as a parameter and adds it to the movieList. Cinema class has ticketSat method. It takes two parameters as User and Movie. User who bought a ticket If you are under the age of 18, apply a 15% discount and deduct from the user's balance if the balance is sufficient. If you want to buy tickets If the user is over 65, apply a 25% discount, and if the balance is sufficient, deduct from the user's balance. If your age is between [18,65] If so, deduct the film's own fee from the user's balance, if the balance is sufficient. If the user's balance is insufficient, give a warning to the screen. Create a test class. Test each method written.

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!