Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

2. Write a function avg_lowest that takes 3 floating values as parameters and returns the average of the two smaller values. For example, if the

image text in transcribed
2. Write a function avg_lowest that takes 3 floating values as parameters and returns the average of the two smaller values. For example, if the input is 2.0, 9.0, 4.0, the output should be 3.0; if the input is 11.5, 6.3, 3.7, the output should be 5.0. Save the function in a PyDev library module named functions.py. A sample run for the function avg_lowest (2.0, 9.0, 4.0) -> 3.0 Write a testing program named to2.py that tests your function by asking the user to input three floating values and printing the average of two smaller values. A sample run of your program: Please enter your first number: 11.5 Please enter your second number: 6.3 Please enter your third number: 3.7 The average of the two smaller value is: 5.0 Or A sample run of your program: Please enter your first number: 6.3 Please enter your second number: 6.3 Please enter your third number: 3.7 The average of the two smaller value is: 5.0 . . Test your program with 3 different data, you may assume that the user will only enter numbers. Copy the results to testing.txt. You are not allowed to use the built-in functions max or min

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Analysis Using SQL And Excel

Authors: Gordon S Linoff

2nd Edition

111902143X, 9781119021438

More Books

Students also viewed these Databases questions

Question

What are the Five Phases of SDLC? Explain each briefly.

Answered: 1 week ago

Question

How can Change Control Procedures manage Project Creep?

Answered: 1 week ago