Test case
|
|
Solution 1: accepted
Well…this is a 2ms solution, but only beats 2%! We have to do more!
Solution 2: accepted
We only need to concatenate what’s left to the final result. This will significantly improve the performance when one list is much longer than the other.