Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
OP solved the task, closing
You have to use return instead of printf
This comment is hidden because it contains spoiler information about the solution
Hi Lorenzo, this is not a kata issue. Please note that there are over 400 solves in C language; if there was such a bug with the first sample test, it would have been discovered long ago. Re-check your code: it returns
0
no matter what.Thanks for mentioning the language. Also, it's good that you are looking at error messages, which are telling you is that for intput
4
, the expected answer is3
, but your code did not provide that. I suggest try using some printf statements to see what your code is doing.