Move Zeros

Move Zeros

You are given a list of integers. Move all zeros in the list to the end of it. The order of non-zero elements should not change.

Input: A list of integers.

Output: A list or another Iterable (tuple, genenator, iterator) of integers.

Examples:

assert list(move_zeros([0, 1, 0, 3, 12])) == [1, 3, 12, 0, 0]
assert list(move_zeros([0])) == [0]