Your thoughts on starting this swapping logic from start vs end? Feels like its much easier and more accurate doing from the end, loop til the counter reaches the start - swap while you find a 0
Solve it however you'd like really, I'm sure there's more than 1 way to do it. Either way you will parse the array once. Just make sure you have the same complexity for your algorithm and it should be fine
What an amazing channel, my brother! Love it a lot
Your thoughts on starting this swapping logic from start vs end?
Feels like its much easier and more accurate doing from the end,
loop til the counter reaches the start - swap while you find a 0
Solve it however you'd like really, I'm sure there's more than 1 way to do it. Either way you will parse the array once. Just make sure you have the same complexity for your algorithm and it should be fine
Thank you for this! Would it be possible to make one for 249. Group Shifted strings?
Could have sworn I already did that one but I guess not. Will add it to the queue