fixed digit, added a couple more tests. It looks done!