Question: so I have failed the test which asks me to fix the decimal place. another method we have learned about is str.format(), however, I only

so I have failed the test which asks me to fix thedecimal place. another method we have learned about is str.format(), however, Iso I have failed the test which asks me to fix the decimal place.

another method we have learned about is str.format(), however, I only know how to use the method when I am print but not when I am returning the value.

can I please have some help? cheers

Files Zame x Shop comb x in Labox fixed x pytho * Pythu x Visual x PCOMIX C Gotll + - 9 X c o Apps c oderunner3.auckland.ac.nz/moodle/mod/quiz/attempt.php?attempt=14748cmid=13&page=48scrollpos=1967.333374023... Com O M U T#* - Google Sh... COMPSCI 101 Google Drive Gmail Chegg Study Desmos | Graphing... COMPSCI 130 Personal Portal - Pe. Other bookmarks CodeRunner3 (Development Server) Jessica Yang print(result) Answer: (penalty regime: 0, 0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50 %) 1 def get_square_root_divide(x, y): try: square_root = math.sqrt(x) quotient = square_root / y return round (quotient, 2) Hammonem except ValueError: return "negative square root" except ZeroDivisionError: return "division by zero" except TypeError: return "operands not numbers" 16-34 O Type here to search A . o ENG 16/01/2020 W Test Expected Got result = get_square_root_divide ( 125, 5) print(result) 2.24 2.24 division by zero division by zero result = get_square_root_divide ( 125, 0) print(result) negative square root negative square root ~ result = get_square_root_divide(-125, 5) print(result) result = get_square_root_divide(100, "a") operands not numbers operands not numbers print(result) 0.3 result = get_square_root_divide (900, 100) 0.30 print(result) 14.00 14.0 result = get_square_root_divide (4900, 5) print(result) Some hidden test cases failed, too. Your code must pass all tests to earn any marks. Try again. Show differences

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!