Fixed the first mistake.
Using pad() the wrong way. My brain is like a popsicle.