without_ten¶
Return a version of the given list where all the 10’s have been removed. The remaining elements should shift left towards the start of the list as needed, and the empty spaces a the end of the list should be 0. So {1, 10, 10, 2} yields {1, 2, 0, 0}. You may modify and return the given list or make a new list.
This exercise was taken from codingbat.com and has been adapted for the Python language. There are many great programming exercises there, but the majority are created for Java.