add another two methods to solve the permutations problem