You are viewing a single comment's thread. Return to all comments →
I added a Trim() after the ReadLine() and that fixed the runtime error.
string arr_temp = Console.ReadLine().Trim().Split(' ');
That was fun to find -_-
You saved my butt, I was passing all my test cases but getting an error on the submission cases. They really need to make sure that at least one or two of the submission cases are actually runable in the editor, all of these where too big.
Wow, here I am trying to solve this problem for the first time, not sure if my solution even makes sense, and it turns out there was an error reading the input T_T.
Anyways thanks for the fix dude!