spirited_away_'s blog

By spirited_away_, history, 5 years ago, In English

Here are two submission for problem d , of ABC 087. one is giving due to declaration of int xdp[][] and int ydp[][] while other is passing using bool xdp[][] and bool ydp[][] .

Any idea, why its happening so!

AC : https://atcoder.jp/contests/abc082/submissions/5496820

int RE : https://atcoder.jp/contests/abc082/submissions/5496847

code :

Spoiler
  • Vote: I like it
  • +3
  • Vote: I do not like it

| Write comment?
»
5 years ago, # |
  Vote: I like it +8 Vote: I do not like it

Have you tried the custom invocation tool? You should be able to figure out the cause yourself using that.

»
5 years ago, # |
  Vote: I like it +1 Vote: I do not like it

it's because stack overflow, i changed your xdp and ydp array to vector (so that the elements stored in heap) and it accepted.

https://atcoder.jp/contests/abc082/submissions/5499771