Problems
Contests
Account
Problems
> Returns to the Origin > Editorial
Returns to the Origin — Solution & Editorial
Back to the Problem
Simulate and test for (0, 0) after every step.
Complexity:
O(|S|)
×
Refer Job