+ 2

How do I run tests when doing the practice problems?

I have written a function which solves the problem, then I run the tests and I get 'no output' - do I need to write something else in the code to get the tests to run properly? (I'm using Python 3) thanks

22nd Feb 2020, 10:49 PM
Stefan
4 odpowiedzi
0
Thank you. This still doesn't work though. Just wondering if I'm inputting it right. Is there a specific code to input to run in order to pass the test cases? Like input() or something?
8th Mar 2020, 7:07 PM
Stefan
0
Thank you, but I'm still having problems. E. G for the Popsicles challenge, this is my python code. It fails all tests: def giveoreat(siblings,popsicles): if floor(popsicles/siblings) == popsicles / siblings: return 'give away' else: return 'eat them yourself' a = giveoreat(input()) print(a) Anything I'm doing wrong here? Thanks
9th Mar 2020, 6:36 PM
Stefan