Cleanup py3k implmentation thanks to @joshbohde for showin the way

py3k is new for me, so my initial attempt was a littl messy. I
noticed that @joshbohde was already ahead of me, and I copied his
commits.

Thanks!