Codeforces Problem 120F Runtime error

I tried solving problem 120F on codeforces here’s the link for that https://codeforces.com/problemset/problem/120/F . I’m also attaching my code which seems to run fine on ideone (https://ideone.com/HiOD03 ) still I don’t know why I’m getting runtime error with this as verdict -> “Exit code is -1073741819” . Can someone help me with this ? What exactly does that exit code mean ?

The problem is you didn’t read the darn task carefully. Read it again