Question: Objectives: To practice writing classes To have some fun Background: This week we'll be writing a program simulating a demolition derby. For those who don't
Objectives:
To practice writing classes
To have some fun
Background: This week we'll be writing a program simulating a demolition derby. For those who don't know, a demolition derby is where the winner isn't the fastest car, but the car that can take a lot of punishment being hit by other cars and still keep moving. In fact, the winner is the last car that is still moving.
Assignment: This program reads from a file that contains the names of the competitors. The results of the crashes are based on random numbers. To make sure that grading works correctly, the user will enter a seed which will be used to generate the output from the solution as well as the output from the code submitted rather than relying on both programs being run at the same time. The code that controls the derby is written. However, it uses a class named Car that is up to you to create.
Required: Create a class named Car. You will need to write the following methods for it:Sample Execution: xx zqyLAB: Demolition DerbyACTIVITY: Demolition DerbySubmission InstructionsDownloadable filesmanpyandDownload
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
