Program that shows the menu options

Assignment Help C/C++ Programming
Reference no: EM132432109

Project Description

Program that shows the following menu options and lets the user to convert from Metric to Imperial system:

Converter Toolkit

1. Temperature Converter

2. Distance Converter

3. Weight Converter

4. Quit

  • If the user enters 1, the program should ask for the temperature in Celsius and convert it toFahrenheit
  • If the user enters 2, the program should ask for the distance in kilometers and convert them to miles.
  • If the user enters 3, the program should ask for the weight in kilograms and convert them to pounds.
  • If the user enters 4, the program should end.

Input Validation: 

  • Do not accept a number outside the range of 1 through 4 for the menu option. Be sure to display appropriate error message if the input is invalid.
  • Do not accept negative numbers for distance and weight. Be sure to display appropriate error message if the input is invalid.
  • Do not accept zero for distance and weight.Be sure to display appropriate error message if the input is invalid.

Examples.JPGProcessing Requirements

1.  The program should use at least one selection control structure (if - else statement)

2.  Use the following for converting input (these are constants):

  • 1 kilometer = 0.6 mile,
  • 1 kilogram = 2.2 pounds,
  • The formula for converting Celsius degree to Fahrenheit is:

F = (9/5)*C + 32 where F is the temperature in Fahrenheit and C is the temperature in Celsius

3.  Convert temperature to a whole number such as 78, distance to two positions after decimal point (for example 84.56) and weight to one position after decimal point (For example 121.6).

Reference no: EM132432109

Questions Cloud

Incorporate the concepts that you have learned : For part one of this project, you will incorporate the concepts that you have learned so far in the course.
Discusses effect of government intervention on recessions : Discusses the effect of government intervention on recessions. You need to focus on the Abstract, Introduction, Results, and Conclusion.
Discuss the Technologys impact on human rights : Discuss the Technologys impact on human rights so my part is Artificial Intelligence and Robotics.
Think about the products that you use : Think about the products that you use. Are there products that you feel did a good job of ensuring security during setup?
Program that shows the menu options : Program that shows the following menu options and lets the user to convert from Metric to Imperial system:
Pro forma forecast for real company : Pro forma forecast for a real company: the students will pick a real-world company and forecast its AFN
What is the estimated NPV of the project : What is the estimated NPV of the project if the after-tax cost of capital (discount rate) is 12%? Use the built-in NPV function in Excel
Define the terms Racism and the shifting political landscape : Define the terms Racism and the shifting political landscape,Public health and reducing disease and accidental death,Voting right and violence,Personal change
Implementations of fibonacci number program : Discuss the implementations of the Fibonacci Number program at the end of this section to consolidate the students' understanding of the while loop repetition

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Implement the program and find the item

This would be a function called into program. Struggling with the search aspect. Any clarification is greatly appreciated. File is 'inventory.dat'

  Program that takes a number between

Write a program that takes a number between -121 and 121 and output that number in the format of power of 3 (1,3,9,27)example:13 = 9+3+1

  Two for loops that will calculate the sum of all even number

Write a program using two for loops that will calculate the sum of all even numbers between 2 and 100,

  Write a c function called resistance which reads adc channel

Write a C function called sensor to read the status of all sensors and return a single byte (short int) whose value is 0 if no sensor is active, 1 if the ‘core placed' sensor is active, 2 if the ‘winder' sensor is active, or 3 if the ‘test point' ..

  Write a function which adds the two numbers

In C write a function which adds the two numbers. Test this function by calling from the main. In main, the user should be asked to provide the two numbers.

  Display currency conversion for us dollar

Write a MATLAB script to display currency conversion for US Dollar, British Pound, Euro with Singapore Dollar as the base Currency. Your output should show the equivalent values for USD, GBP, EURO for every Singapore dollar in increments of 1 doll..

  Write function that is passe an array of n pointers to float

Write a function that is passed an array of n pointers to floats and returns a newly created array that contains those n float values. Implement a function for integrating a function by means of Riemann sums.

  Returns the number of even elements in the list

You're asked to extend the circular Linked List of integers by adding the following new methods: CountEven, IncrementInfo, Sorted, EvenSublist, and addList

  Program - keep track of both a cd and a dvd collection

Create a class called Date - The class will have the following data members - Create a class called EmployeeInfo which inherits from the Person class.

  Repare a c++ class derived that inherits from base class

Write a C++ class Base has two member functions: //add constructor(s) if needed int f () {return x*25;} //x is a protected data member of Base class virtual int g() {return x *35; }

  Write a program to operate the pololu robot

ENSE504 Introduction to Computing Assignments. Write a program to operate the Pololu robot so it follows a black line on the floor

  Describe the three levels of data abstraction

Describe the three levels of data abstraction? Define the "integrity rules". What is extension and intension?

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