I walk through the thought, coding as well as explaining how to drive the time and space complexity
Note: At 8:30 odd-1 should be equal even (second from the bottom up) and (odd-1)/2 should be equal even/2 at the bottom. So (odd-1)/2 is closer to 0 than odd-1 at a given time.