Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Try submitting the program for grading ( click Submit mode, then Submit for grading ) . Notice that the first two test cases fail, but
Try submitting the program for grading click "Submit mode", then "Submit for grading" Notice that the first two test cases fail, but the third test case passes. The first test case fails because the program outputs the result from the kilotopounds function, which has an error. The second test case uses a Unit test to test the kilotopounds function, which fails.
Change the kilotopounds function to multiply the variable kilos by instead of dividing. The return statement should be: return kilos Submit again. Now the test cases should all pass.def kilotopoundskilos:
# This statement intentionally has an error.
return kilos
# Main part of the program starts here. Do not remove the line below.
if namemain:
kilos floatinput
pounds kilotopoundskilos
printfpounds:f lbs
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started