숫자 배열에서 0을 마지막으로 보내는 배열을 만드는 것이다.
단 배열을 추가하면 안되는 조건이었다.
def move_zeroes(nums): count = nums.count(0) while 0 in nums: nums.remove(0) for j in range(count): nums.append(0) return nums
0의 개수를 세주고
0이 반복되는 동안 0을 제거해주고 나중에 0을 뒤에 붙혀주었다.