sazerterus25's blog

By sazerterus25, history, 9 years ago, In English

Can someone please tell me why I am getting Runtime Error using this code: http://ideone.com/8m5Bve Problem is C. Substitutes in Number. Codeforces Round #265 (Div. 1)

http://mirror.codeforces.com/contest/464/problem/C

  • Vote: I like it
  • -1
  • Vote: I do not like it

»
9 years ago, # |
  Vote: I like it 0 Vote: I do not like it

You need to provide an input too http://ideone.com/IQPqTt

  • »
    »
    9 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    I am sorry, I could not get you. Should I provide the input test case on which I failed? I am sorry, but I am not able to do that. Since the test case on which I failed I cannot see in codeforces. Also, I was not talking about the runtime error in Ideone, rather the error I faced when I submitted in codeforces.

    • »
      »
      »
      9 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      I'm not sure why you've maintained a string array. You don't need to access a string after it has been used once for querying. So use a simple string instead. The string array might be causing this error because of the huge space it may consume in the worst case.