Question: Python so far I have: however, unit test failed Problem limproductorsum Given two values representing two integers, return their product if it is less or

Python

Python so far I have: however, unit test failed Problem limproductorsum Given

so far I have:

two values representing two integers, return their product if it is less

however, unit test failed

Problem limproductorsum Given two values representing two integers, return their product if it is less or equal than the threshold, Otherwise, return their sum. Example with product: value1 2, value2 3, threshold = 100 will return 6 Example with sum: value1 = 2, value2 = 100, threshold = 100 will return 102 ILULUI Edef product_or_sum(valuel, value2, threshold=100): : value1: an integer representing the first value :value2: an integer representing the second value :threshold: an integer representing the limit for the product of the two values :return: the product or the sum of both values result = 0 # TODO: your code here return result def product_or_sum(value1, value2, threshold=100): INNI :value1: an integer representing the first value :value2: an integer representing the second value :threshold: an integer representing the limit for :return: the product or the sum of both values ILIRI result = 0 # TODO: your code here if value1

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!