Question: Exercise . Create three arrays as defined below that contains the information based on cars: carName = {Ford, BMW, Mercedes, Chevrolet} %3D carCountry =

Exercise . Create three arrays as defined below that contains the information

Exercise . Create three arrays as defined below that contains the information based on cars: carName = {"Ford", "BMW", "Mercedes", "Chevrolet"} %3D carCountry = {"American", "German", "German", "American"} carPrice = (10000, 12000, 13000, 12500} a. In your main, create a program that asks the user for two integer values between 1 and 4, inclusive. Using the array, your program should print out the names of cars and country of manufacturing corresponding to the numbers the user entered. Your program must REJECT any numbers that's outside this range. b. On a new line, print which car is a cheaper option. An example printed output for Q1 could be: "Please enter two numbers: 43 The cars you chose are Chevrolet which is American made, and Mercedes which is German made. The price of Chervrolet: 12500 is cheaper than Mercedes: 13000"

Step by Step Solution

3.43 Rating (159 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

C Code include using namespace std int main int xy ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!