Re: A fast way to judge an anagram




Chris Uppal wrote:
BTW, how did you find the AAAAAAAAAJOV / BBBBBBCCCCEE example ?

I started with something like
foreach n (55130{0,1,2,3,4,5,6,7,8,9}
{0,1,2,3,4,5,6,7,8,9}{0,1,2,3,4,5,6,7,8,9})
factor $n
end
though only to get several thousand results (not 55 million!) then did
grep -v ":.*[0-9][0-9][0-9]"
to get rid of factors too big (accidentally excluding Z=101 as well).
The resulting file could have been awk'ed to find adjacent numbers,
but I found it easier to write a quick C program (taking care not to
let
the "gets() dangerous" message bother me :-).

Quickly browsing through the final results I spotted one where the
"false
anagrams" had equal numbers of (smallish) symbols.

James

.