Its often necessary to convert between units in this


Given a simple problem, design and desk-check a solution algorithm requiring a modular design that is expressed in terms of pseudocode or program notes, input-process-output (IPO) analysis, and flow chart.

Given a program with logic errors that is intended as a solution to a simple problem, employ debugging diagnostics to remove and correct the errors.

Given a more complex problem, develop a complete solution that includes a comprehensive statement of the problem, complete program design, and program documentation.

Assignment

It's often necessary to convert between units. In this exercise, you will create two functions for converting between units of distance. The first function will be called ConvertMilesToKilometers(), which will accept one parameter for the number of miles. It will return the equivalent number of kilometers. The second function will be called ConvertKilometersToMiles() and will accept kilometers as its parameter; this will return the equivalent number of miles.

The main method will ask the user if he or she wants to convert miles to kilometers or kilometers to miles. It will then ask for the number of miles or kilometers. It will call the appropriate method and display the converted value.

To convert miles to kilometers, divide miles by 0.62137. To convert kilometers to miles, multiply kilometers by 0.62137.

Request for Solution File

Ask an Expert for Answer!!
Data Structure & Algorithms: Its often necessary to convert between units in this
Reference No:- TGS01090565

Expected delivery within 24 Hours