102615607 gets stack overflow but runs fine locally. I'm generating input according to this comment (BledDest correct me if I'm wrong), and I'm using vm arguments -Xmx1024m -Xms64m
, as suggested by the memory limit and this blog. Just in case testcase 50 was generated differently, I also tried generating input using n = 1e8 which worked fine, albeit taking 150 seconds and requiring a lot more memory. So now I am somewhat confused: Why am I getting stack overflow?
Input generation