Page 1 of 1

I ONLY WANT PARTS C&D SO PLSSSSS HELP ITS URGENTTTT PLS BE SURE TO CHECK THE PHOTOS

Posted: Thu Jun 02, 2022 8:23 am
by answerhappygod
I ONLY WANT PARTS C&D SO PLSSSSS HELP ITS URGENTTTT
PLS BE SURE TO CHECK THE PHOTOS
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 1
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 1 (49.67 KiB) Viewed 13 times
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 2
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 2 (49.67 KiB) Viewed 13 times
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 3
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 3 (53.03 KiB) Viewed 13 times
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 4
I Only Want Parts C D So Plsssss Help Its Urgentttt Pls Be Sure To Check The Photos 4 (42.73 KiB) Viewed 13 times
Implement the following classes. Assume having a club that provides two racing games: car racing and horse racing. RacingGame teaml:String team2:String + RacingGame(t1:String, 12: String) +toString(): String +getter/setters() CarRace Horse Horses Hourse [] name: String age: int type1:String yearl String type2: String year2: String + HorseRace(All parameters) + getHorsel(): Horse + getHorse2(): Horse + Horse (All parameters) + getName(): String + getAge(): int + CaRace(All parameters) + toString(): String + toString(): String + getters/setters() A. RacingGame class is characterized by two String attributes team1 and team2. This class has as methods: A constructor that initializes the attributes. [5 pts] . . A toString method that returns the information in the form TeamNamel vs TeamName 2. [5 pts] getter/setter methods. [5 pts] HorseRace b
A. RacingGame class is characterized by two String attributes team1 and team2. This class has as methods: A constructor that initializes the attributes. [5 pts] • A toString method that returns the information in the form TeamNamel vs TeamName2. [5 pts] getter/setter methods. [5 pts] B. The CarRace class that inherits from RacingGame. It has four String attributes the type (e.g. Honda) and the year (e.g. 1998) of the first team and those of the second team. This class has as methods: • A constructor that initializes all attributes. [5 pts] • A toString method that returns the information in the following form. [5 pts] TeamNamel vs TeamName2 - Honda 1998 vs BMW 1997 • getter/setter methods. [5 pts] C. HorseRace class inherits from the class RacingGame. It has as an attribute an array of 2 horses and as methods: A constructor that initializes all attributes. [5 pts] A method getHorsel0 that returns the first horse object in the array. Write this method. [5 pts] A method getHorse20 that returns the second horse object in the array. Write this method. [5 pts] A toString method that returns the information of the two horses in the following forms. [5 pts] TeamNamel vs. TeamName - horseNamel Agel vs horseName2 Age2 D. The Class "Horse" has as attributes the age (int) and the name (String) and as methods: . A constructor that initializes all attributes. [5 pts] • The getter methods (getName() and getAge()). Write the two get methods. [5pts]
D. The Class "Horse" has as attributes the age (int) and the name (String) and as methods: A constructor that initializes all attributes. [5 pts] • The getter methods (getName() and getAge()). Write the two get methods. [5pts] Page 1 of 2 CSC1300LAB Final Exam Spring 2021-2022 Create an application as follows: Assume we have an array called games of RacingGame objects that can store up to 10 objects. Assume also that the user enters the information of as many HorseRace objects and CarRace objects as he/she wants as long as the number does not exceed 10. These objects are filled in the array games. The corresponding code is provided below. [10 pts] a) Write code to count the number of Horse Race games. [10 pts] b) Write code to count the number of cars made in 1998. [10 pts] e) Write code to display the names of the aged horses which are over 4 year old. [10pts]