Leading zeros fix

This addresses part of the issues listed in #5. Namely the requirement that there are no leading zeros.