Question: using c++ QUESTION 4 (15 MARKS) The following struct declaration is used to keep the data of cars rented in a rental company: struct Rentalcar
using c++

QUESTION 4 (15 MARKS) The following struct declaration is used to keep the data of cars rented in a rental company: struct Rentalcar { int ID; string model; bool auto; }; a) A maximum of 20 cars can be rented per day. Declare a constant named SIZE with value 20. (1 mark) b) To keep the list of cars rented, declare an array of RentalCar named rentlist that can hold maximum number of rented cars per day. Use the constant SIZE declared. (2 marks) c) The first car rented has ID of 1001. Assign the number to the ID of the first element of rentList. (2 marks) d) A car with automatic transmission has its auto value set to true. Define a function to print only the ID and the model of the cars in rentList with automatic transmission. The calling function is written as follows: printAuto (rentList); (10 marks)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
