Блог пользователя ApaarGulati

Автор ApaarGulati, история, 5 месяцев назад, По-английски

hi. i have written the following code for 1742C — Stripes 1742C - Stripes 269473494 it is running fine on Replit and other IDE's but CF shows Runtime Error(Exit Code is 1) i have tried debugging multiple times but there is no error. what should i do??

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

»
5 месяцев назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

there is an empty line between test cases but you haven't handled it properly when reading the input

image

  • »
    »
    5 месяцев назад, # ^ |
    Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

    ohhh i totally did not notice that thanks a lot!!

    edit: hi. i made the appropriate changes to handle the empty line but apparently in the second test, there is a test case(test case 10 which seems to be causing problems) but according to me code is working fine. is it possible that the input in the test case might not be a valid input??