isPermutation() implemented, all tests passing