Added new method to String

New method to calculate number of unique permutations of a string.
Recursive method to calculate rank.