Refactor and make work

It was a one character typo that was causing the tests to fail ([1:] vs.
[:1])

More readable and tested.