Question
(PYTHON) 17.6 Convert Units: Feet to Metres You are required to convert height from foot/inches into metric system. The input will be specified in feet
(PYTHON) 17.6 Convert Units: Feet to Metres You are required to convert height from foot/inches into metric system. The input will be specified in feet and the output needs to be in metres. Reference: 1 Feet = 0.3048 Metres Output each floating-point value with two digits after the decimal point (Hint: Use the round function) If the input value is lesser than or equal zero, then throw an AssertionError with the message: "Input must be non-negative" You have been provided with a template code. Please write the implemientation for inchesToMetres function.
You are required to convert height from foot/inches into metric system. The input will be specified in feet and the output needs to be in metres. Reference: 1 Feet =0.3048 Metres Output each floating-point value with two digits after the decimal point (Hint: Use the round function) If the input value is lesser than or equal zero, then throw an AssertionError with the message: "Input must be nonnegative" You have been provided with a template code. Please write the implementation for inchesToMetres function. Ex: If the input is: 5.4 Expected output: 1. 64 Ex: If the input is: 3 Expected output: Note: The input will be completely specified in feet. Inches will not explicitly specified. You can ignore the specific stack trace produced by the Python interpreter. The focus is on generating the correct AssertionError messageStep 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