logo Hurry, Grab up to 30% discount on the entire course
Order Now logo

Ask This Question To Be Solved By Our ExpertsGet A+ Grade Solution Guaranteed

expert
Jason ParkerrEngineering
(5/5)

629 Answers

Hire Me
expert
Feuer YaoData mining
(5/5)

794 Answers

Hire Me
expert
Earl BarwinnNursing
(5/5)

949 Answers

Hire Me
expert
Alexx WardEconomics
(5/5)

986 Answers

Hire Me
Others
(5/5)

Write the algorithm and the corresponding program to calculate the acceleration of a vehicle given the speed in miles per hour and the time in seconds

INSTRUCTIONS TO CANDIDATES
ANSWER ALL QUESTIONS

Acceleration is the rate at which an object changes its velocity. It is typically represented by symbol a and measured in m/s2 (meters per second squared).

Write the algorithm (steps in pseudocode) and the corresponding program to calculate the acceleration of a vehicle given the speed in miles per hour and the time in seconds. Use the formula provided below to calculate the acceleration in meters per second squared.

The program must prompt the user to enter a velocity in miles per hour and a time in seconds (real numbers) and then display the resulting acceleration as a real number. The acceleration must be rounded off to one decimal digit but displayed with two decimal digits.

Acceleration formula: a = 1609/3600 x v/t 

a: acceleration in meters per second squared

v: velocity in miles per hour

t: time in seconds

Mandatory:

1. Use a constant MPH2MPS = 1609/3600 for converting from miles per hour to meters per second.

2. Use the function learned in class to round off the acceleration.

3. Use appropriate data types for variables and constants.

4. Display the output formatted as in the example shown below.

Review the examples discussed in class, the lab assignments are done so far, and the Programming Examples in the tutorial to get an idea of what you need to do. The algorithm must be written in pseudocode and should look like my lab handouts. Include your algorithm in the source code as comments.

Sample run of the program

Acceleration calculator

Please enter the velocity in miles per hour: 60

Please enter the time in seconds: 6

The acceleration required by a vehicle to reach a velocity of 60.00 miles per hour in 6.00 seconds is 4.50 meters per second squared

IMPORTANT:

For your reference on how the program should interact with the user, I am providing sample runs of my solution. Run your program with the same values I use in CSCI 1380 Summer II 2021 Mr. Gustavo Dietrich them and make sure your program behaves similarly to mine (pay attention to the values calculated).

Your program must be well commented, use meaningful identifiers, use the constant.

Do not hesitate to use the corresponding forum in Discussions to post your questions/doubts about this assignment. I will reply as soon as I can.

Your program must have the following comments at the top: 

Your full name

Partner’s full name (ONLY if you worked with a partner)

(Brief description of what the program does)

Sample runs of my solution

Acceleration calculator

Please enter the velocity in miles per hour: 60

Please enter the time in seconds: 4.5

The acceleration required by a vehicle to reach a velocity of 60.00 miles per hour in 4.50 seconds is 6.00 meters per second squared

Acceleration calculator

Please enter the velocity in miles per hour: 73.

2 Please enter the time in seconds: 5.23

The acceleration required by a vehicle to reach a velocity of 73.20 miles per hour in 5.23 seconds is 6.30 meters per second squared

Acceleration calculator

Please enter the velocity in miles per hour: 55

Please enter the time in seconds: 6

The acceleration required by a vehicle to reach a velocity of 55.00 miles per hour in 6.00 seconds is 4.10 meters per second squared

Acceleration calculator Please enter the velocity in miles per hour: 60

Please enter the time in seconds: 6

The acceleration required by a vehicle to reach a velocity of 60.00 miles per hour in 6.00 seconds is 4.50 meters per second squared

(5/5)
Attachments:

Related Questions

. The fundamental operations of create, read, update, and delete (CRUD) in either Python or Java

CS 340 Milestone One Guidelines and Rubric  Overview: For this assignment, you will implement the fundamental operations of create, read, update,

. Develop a program to emulate a purchase transaction at a retail store. This  program will have two classes, a LineItem class and a Transaction class

Retail Transaction Programming Project  Project Requirements:  Develop a program to emulate a purchase transaction at a retail store. This

. The following program contains five errors. Identify the errors and fix them

7COM1028   Secure Systems Programming   Referral Coursework: Secure

. Accepts the following from a user: Item Name Item Quantity Item Price Allows the user to create a file to store the sales receipt contents

Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip

. The final project will encompass developing a web service using a software stack and implementing an industry-standard interface. Regardless of whether you choose to pursue application development goals as a pure developer or as a software engineer

CS 340 Final Project Guidelines and Rubric  Overview The final project will encompass developing a web service using a software stack and impleme