make_last¶
Given an int list, return a new list with double the length where its last element is the same as the original list, and all the other elements are 0. The original list will be length 1 or more. Note: by default, a new int list contains all 0’s.
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.