This comment is hidden because it contains spoiler information about the solution
40 is your answer, 40 + 2 is the expected one. Not a kata issue. You're returning inside the loop at its first iteration.
Your function currently prints check instead of returning it. In a Codewars kata, you should be returning the result from your function rather than printing it. Make sure to use a return statement to output the result.
This paragraph has some information on your problem, see if it will be helpful for you.
Loading collection data...
This comment is hidden because it contains spoiler information about the solution
40 is your answer, 40 + 2 is the expected one. Not a kata issue. You're returning inside the loop at its first iteration.
This paragraph has some information on your problem, see if it will be helpful for you.