Answered step by step
Verified Expert Solution
Question
1 Approved Answer
use java use polymorphism het location and might be unsae (4) (50 marks) Polymorphic Movies listing For this exercise, you have a list of movies
use java use polymorphism
het location and might be unsae (4) (50 marks) Polymorphic Movies listing For this exercise, you have a list of movies that you want to list it in a random order. This list consists of five movies. The purpose of this exercise is to demonstrate how you use the polymorphism technique to display the info of a selected movie. The selection is done usinga random number generator. Each movie has a structure of (string movie name, string one-liner, string actor). The movie class also has methods that return the movie name, the one-liner and the key actor (see table below) Your movie list is arranged in a specific number as show in the following table A one-liner actor number name Robert Shaw 1 Jaws We need a bigger boat Independence 2 day No oops! Will Smith 3 Bourne Identity A man with numerous passports 4 Star Wars 5 12 Angry men Open and Shut Case Matt Damon Harrison Ford Henry Fonda Resistance is futile (Sor ry these movies are a bit outdated, you can replace them with your favorite movies) Your display should look similar to the following results. The order of display depends on the Random # number generator. Many of you may try to use the switch-case (or worst using "if thenStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started