In round #216, I tried to hack this code. As you see, there is a line written this:
int tp = (sa - sk) % (n - k);
If n = k, then the code must get RE because of division by zero. But the code has been accepted!
Can someone explain this behavior of C++?