# Tate Trenkamp Lab 3 - Introduction to Functions Lab 3...

• 5

This preview shows page 1 - 3 out of 5 pages.

Introduction to Functions Lab 3 Section 3 SUBMITTED BY: TATE TRENKAMP SUBMISSION DATE 9/26/2019 Part 1:
The objective is to make the 4 columns of code have a certain amount of digits and decimal places. The requirements are the code must outputs seconds, ax, ay, az separated by commas, seconds is displayed as a real number in an 8 character area with 3 decimal digits of precision, and each acceleration is shown in a 7 character area with 4 digits of precision. Analysis: The code has to end up showing seconds in 8 digits with 3 digits of decimal precision, and each acceleration in 7 digits with 4 digits of precision. Design: First the code must output the seconds and acceleration in a line with each separated by commas. Then you must put 8.3 between % and lf in the place where the seconds value is in the print statement. Then you have to put 7.4 in betweeen % and lf for each acceleration. Testing: To test the code you have to see if the code output on the screen shows seconds in the format 00000.000, and shows all the accelerations in the format 000.0000 Comments: I learned how to change the digits shown in c.
• • • 