Code changes for permuteString class