Question: c++ 13 Create a class called Vehicle that keeps track of a vehicle. It should have: a constructor that sets the type (string) and the
13 Create a class called Vehicle that keeps track of a vehicle. It should have: a constructor that sets the type (string) and the (int) top speed. a default constructor that sets the top speed to 1 and the name to "unknown" a getter for type and the top speed a setter for the top speed The setter should validate that the top speed is between 0 and 1000. a getSpeed Category() method that returns the classification for the top speed. o Between 0 - 20 - "Category 1. Slow" o Between 21-50 - "Category 2: Average" Between 50 - 100 - "Category 3 : Fast" IN Between 100 - 200 Category 4: Accelerated" 200+ Category 5 - Unsafe" Make sure to comment the include guard so that I know you know where it is
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
