HALLOWEEN VS CANDY | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

HALLOWEEN VS CANDY

You go trick or treating with a friend and all but three of the houses that you visit are giving out candy. One house that you visit is giving out toothbrushes and two houses are giving out dollar bills. I m considering number of houses that are giving bills are fixed but some test cases on this logic are wrong.. !!NEED HELP!! #MYLOGIC houses = int(input()) print(round((2/houses)*100))

14th May 2020, 8:18 AM
Nikhil Jain
Nikhil Jain - avatar
3 Answers
+ 1
There is no Round function is Python. Instead u shld from math import * And then use math.ceil function. that should help. thank you.
14th May 2020, 6:23 PM
Tejas Amit Sheth
0
Ohh! Ok thanks buddy
14th May 2020, 6:25 PM
Nikhil Jain
Nikhil Jain - avatar
0
No Issues Anytime.
14th May 2020, 6:26 PM
Tejas Amit Sheth