How many automobiles are to be described

Assignment Help Basic Computer Science
Reference no: EM13219647

Write a program that asks the user how many automobiles are to be described, and for each automobile it inputs the user's selection of make and color. Then it outputs color and make. Although you could do this easily using a simple procedural program, do it by using a main method in class AutomobileDriver to instantiate an object called auto from a class Automobile. In the Automobile class, do the following: Create a setMake() method. In this method, prompt the user "Input make of auto: ". Store their input into a make variable. Create a setColor() method. In this method, prompt the user "Input color of auto: ". Store their input into a color variable. Create "getter" methods for make and color. Create a printAll() method. In this method, print the color and make of the automobile on one line in accordance to the sample session given below. In the AutomobileDriver class, do the following: Create an instance of Automobile. Call the setMake() method. Call the setColor() method. Call the printAll() method. Be sure your output is similar to the following: How many autos do you want?: 2 Enter make: Honda Enter color: Blue Enter make: Chevy Enter color: Red You have a Blue Honda. You have a Red Chevy.

Reference no: EM13219647

Questions Cloud

How much would unit sales have to increase : How much would unit sales have to increase before her gross profit would be no less than prior to the price decrease?
Steps in the scientific method : steps in the scientific method and show how a psychologist would use each of them to improve the office's productivity
Should the event be interpreted as evidence : During the oil crisis in the 1970s, long lines at gas stations disappeared soon after price controls were removed and gas prices were permitted to rise. Should this even be interpreted as evidence that the oil companies have monopoly power
Explain carbon dioxide is dissolved in blood : Carbon dioxide is dissolved in blood to form a mixture of carbonic acid and bicarbonate. Neglecting free CO2 what fraction will be present as carbonic acid?
How many automobiles are to be described : How many autos do you want?: 2 Enter make: Honda Enter color: Blue Enter make: Chevy Enter color: Red You have a Blue Honda. You have a Red Chevy.
Compute the price charged for each moldboard plow : The firm employs 300,000 direct labor hours and incurs $400,000 of fixed overhead. Given a markup of 30 percent, compute the price charged for each moldboard plow using the absorption cost method.
Astronomy-helium is very common in the sun : Helium is very common in the Sun and calcium is rare. Why are helium lines weak and calcium lines strong in the visible spectrum of the Sun? How would a star regain its state of equilibrium if the energy generation rate of a star were to become sligh..
How many automobiles are to be described : How many autos do you want?: 2 Enter make: Honda Enter color: Blue Enter make: Chevy Enter color: Red You have a Blue Honda. You have a Red Chevy.
Solve time value of money problems : What is the value at the end of year 5 of $20,000 deposited today which yield 10% compounded semi-annually and You invested $3,000 for 5 years, compounded annually and at the end of 5 years received $4,407. What was your annual interest rate?

Reviews

Write a Review

Basic Computer Science Questions & Answers

  What does the top box, middle box and last box contain

There are three boxes in a Unified Mark-Up Language class diagram. What does the top box, middle box, and last box contain?

  How to make components of system user-friendly

How do components of your computer system interact within system? What improvements or additions to your system do you think would benefit you or make system more user-friendly? Why?

  Better software tool internet explorer or mozilla firefox

There are several Internet browsers available today, and many people select which to use without giving it consideration. Explain which is better software tool: Internet Explorer, Mozilla Firefox, or Google Chrome?

  Describe method to execute account harvesting

Describe the threat of account harvesting. Suggest a method to execute an account harvesting attack on a Windows platform.

  Compute storage in bytes which is needed for frame buffer

If we want to store 6 bits per pixel in frame buffer, how much storage (in bytes) do we need for the frame buffer?

  How analysts compute cost of information system

When the analysts compute the cost of an information system, they seldome include the cost of the employee laybor for using that system.

  Write a mips program to complete the following functions

Write a MIPS program to complete the following functions. You must write comments and follow the register convention.

  Database redesign is working properly in redesign testing

To make sure that database redesign is working properly during redesign testing process, a means should be created to do which of the following?

  Components of computer system interact within system

How do the components of your computer system interact within the system? What improvements or additions to your system do you think would benefit you or make the system more user-friendly? Why?

  Calculate and display the total retail value of all products

calculate and display the total retail value of all products sold. Use a sentinel-controlled loop to determine when the application should stop looping display the final results.

  Actions against company security camera

Joe the janitor is recorded on the company security camera one night taking pictures with his cell phone of the office of the CEO after he is done cleaning it. What will you do and what is your justification for your actions?

  Discuss the issues of encryption and key management

Discuss the issues of encryption and key management in cloud computing, how it different for personal computers and traditional enterprising computing environments.(1300-1400 words)

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd