Shibbir001's blog

By Shibbir001, history, 9 years ago, In English

On a recent contest, i submitted a problem for many times but it shows runtime error. I have checked it in many online g++ compiler. It runs well but codeforces shows runtime error verdict. .

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

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

For (it = s.begin(); it != s.end(); it++)

If ... s.erase(it)

Here is a mistake. you are not allowed to change the size of your set in FOR loop. be careful and use debugger