Sherlock and Anagrams
Two strings are anagrams of each other if the letters of one string can be rearranged to form the other string. Given a string, find the number of pairs of substrings of the string that are anagrams of each other.
///Sample Input
ifailuhkqq
kkkk
cdcd
/// Output
3
10
5