Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Help with creating a car class with the following attributes in C++. .Create a class called CAR. Have several variables - use necessary variables that

Help with creating a car class with the following attributes in C++.

image text in transcribed

.Create a class called CAR. Have several variables - use necessary variables that store gas level, amount of gas, gear car is in, car in motion, etc. Have functions that do: .Check the battery level Check the gas level .Turn right, Left, .Go Straight Put car in forward gear Put car in backward gear Start Car (function should check if batter is good and you have gas) Example: If good then print message "car started", if not " print car not started because..." Park Car Move car # number of feet. (Car uses 1 unit of gas per 50 feet) (subtract 1 unit of gas per 50 feet traveled) As the car moves (determine if it needs gas) Note: as you instruct the computer to perform a command in the main function, have your function print out messages for each action Have a dashboard/Interface in which the user can make interactive/Live choices on how to drive the car

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Upgrading Oracle Databases Oracle Database New Features

Authors: Charles Kim, Gary Gordhamer, Sean Scott

1st Edition

B0BL12WFP6, 979-8359657501

More Books

Students also viewed these Databases questions