You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tech-interview-handbook/questions/09-move-zeroes.md

330 B

id title topics difficulty source
9 Move Zeroes
array
easy https://leetcode.com/problems/move-zeroes/

Question

'''
Given an array of integers, write a function to move all zeroes to the end of it while
maintaining the relative order of the non-zero elements.

[0, 1, 0, 3, 12] => [1, 3, 12, 0, 0].
'''