+ 1

What is the issue?

I was learning Python very smoothly until I came up with the case of restroom count! I made the code as: n = int(input()) for y in range(5,n,5): print(y) It, worked for all cases, except the last one! I looked upon the solution, and tried the same as mentioned but nothing worked! What could be the solution? Kindly assist?

22nd Jul 2022, 8:34 PM
Kaustubh KR
Kaustubh KR - avatar
2 Answers
+ 1
Potentially the output should include floor n, if n is divisible by 5. To do that you would use n+1 as the second argument in range().
22nd Jul 2022, 11:46 PM
Brian
Brian - avatar
0
What is your task there actually? add description.. which python course, lesson, it from ?
22nd Jul 2022, 8:52 PM
Jayakrishna 🇼🇳