added permutation problem