+ 2

Halloween Candy 4/5 using round

I've been trying to beat Code Coach's Halloween Candy challenge today, and in fact I did beat it using ceil in the end. But I kind of wanted to try not to use ceil and came up with the code below. However I can't get the 4th test to pass. Maybe you guys can help me out with this. There isn't any requirement to use ceil, is there? Am I missing something else? https://code.sololearn.com/cLIPy1kvYe5x/?ref=app

2nd Aug 2020, 11:58 AM
Robert Z.
5 Answers
+ 2
I guess it's hard to get it to work like this then, ty.
2nd Aug 2020, 12:14 PM
Robert Z.
+ 2
I use this, no functions used at all: if (2 * 100 % houses == 0): print((2 * 100)//houses) else: print((2 * 100)//houses + 1);
2nd Aug 2020, 1:05 PM
Paul
Paul - avatar
2nd Aug 2020, 2:44 PM
Jayashree Nandan
Jayashree Nandan - avatar
0
Yh for sure, stupid me.
2nd Aug 2020, 7:41 PM
Robert Z.