Re: A fast way to judge an anagram
- From: "James Dow Allen" <jdallen2000@xxxxxxxxx>
- Date: 27 May 2006 02:16:05 -0700
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
.
- Follow-Ups:
- Re: A fast way to judge an anagram
- From: Chris Uppal
- Re: A fast way to judge an anagram
- References:
- A fast way to judge an anagram
- From: buoy
- Re: A fast way to judge an anagram
- From: James Dow Allen
- Re: A fast way to judge an anagram
- From: Chris Uppal
- A fast way to judge an anagram
- Prev by Date: Re: quickly comparing blocks of ints
- Next by Date: Re: Algorithm Question
- Previous by thread: Re: A fast way to judge an anagram
- Next by thread: Re: A fast way to judge an anagram
- Index(es):
Relevant Pages
|