0
Can't pass the 3rd test in No Numerals exercise
https://code.sololearn.com/c2ervSc4jDCZ/?ref=app This is my code, it passes all the tests but 3rd. I can't understand what's wrong with it. I will appreciate your answer!
2 Respostas
+ 2
Vitaliy Reshetar , the problem is that if string contains 10 your output is ten zero => it should be just 10. Based on your logic if you met 1 followed by 0, you should skip not one step but two ( because next is zero and you are checking it twice). Just change line 21 of your code => i+=2;. Look also at the corrected code. Hope now everything is clear 🐱
https://code.sololearn.com/cuS07qRZSn6u/?ref=app
+ 1
By the way it also works if the i++ is added before the second continue (line 26)