# Longest anagram

**URL:** https://boards.straightdope.com/t/longest-anagram/358666
**Category:** Factual Questions
**Created:** [May 29, 2006, 10:49pm UTC](https://boards.straightdope.com/t/longest-anagram/358666 "2006-05-29T22:49:46Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![dauerbach](https://avatars.discourse-cdn.com/v4/letter/d/c2a13f/32.png) [@dauerbach](https://boards.straightdope.com/u/dauerbach)
#### Post date: [May 29, 2006, 10:49pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/1 "2006-05-29T22:49:46Z")

</div>

I’ve been trying to think of a word of greater than four letters that make a single word anagram of identical length. Four is the most I can think of. Anyone have hany ideas?

---

<div class="post-metadata">

### Author: ![GorillaMan](https://avatars.discourse-cdn.com/v4/letter/g/50afbb/32.png) [@GorillaMan](https://boards.straightdope.com/u/GorillaMan)
#### Post date: [May 29, 2006, 10:51pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/2 "2006-05-29T22:51:18Z")

</div>

Try googling ‘longest anagram’. [http://www.asdf.org/~anna/grams/12to17.html](http://www.asdf.org/~anna/grams/12to17.html)

---

<div class="post-metadata">

### Author: ![Majikthise](https://avatars.discourse-cdn.com/v4/letter/m/bb73d2/32.png) [@Majikthise](https://boards.straightdope.com/u/Majikthise)
#### Post date: [May 29, 2006, 11:32pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/3 "2006-05-29T23:32:58Z")

</div>

> [@GorillaMan](#):
>
> Try googling ‘longest anagram’. [http://www.asdf.org/~anna/grams/12to17.html](http://www.asdf.org/~anna/grams/12to17.html)

Here are a few that are not listed in the above website (it seems they don’t include anagrams that repeat strings of more than three letters):  
petrographically = pterylographical (16)  
nonconservational = nonconversational (17)  
incontrovertibility = introconvertibility (19)  
impressivenesses = permissivenesses (16)

There are also a few that follow the form whatever-ism = mis-whatever:  
configurationism = misconfiguration (16)  
constitutionalism = misconstitutional (17)  
representationism = misrepresentation (17)

Here are some larger sets of anagrams:  
gramophonically = monographically = nomographically (15)  
peridiastolic = periodicalist = pictorialised = proidealistic (13)  
espringal = graplines = pearlings = presignal = relapsing = spanglier (9)  
arsenites = atrienses = irateness = resinates = stearines = teariness (9)

All of the above words are found in the Linux words file. I’d be interested to see if anyone can guess the simple algorithm I used to generate these.

---

<div class="post-metadata">

### Author: ![twickster](https://avatars.discourse-cdn.com/v4/letter/t/ec9cab/32.png) [@twickster](https://boards.straightdope.com/u/twickster)
#### Post date: [May 29, 2006, 11:50pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/4 "2006-05-29T23:50:10Z")

</div>

I was gonna give you a couple of six-letter words (how lame of me!):

Nicest/incest

Smiled/misled

---

<div class="post-metadata">

### Author: ![Askance](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/askance/32/8281_2.png) [@Askance](https://boards.straightdope.com/u/Askance)
#### Post date: [May 30, 2006, 1:59am UTC](https://boards.straightdope.com/t/longest-anagram/358666/5 "2006-05-30T01:59:00Z")

</div>

> [@dauerbach](#):
>
> I’ve been trying to think of a word of greater than four letters that make a single word anagram of identical length.

How could an anagram be anything other than identical length? 😕

---

<div class="post-metadata">

### Author: ![Beware\_of\_Doug](https://avatars.discourse-cdn.com/v4/letter/b/278dde/32.png) [@Beware\_of\_Doug](https://boards.straightdope.com/u/Beware_of_Doug)
#### Post date: [May 30, 2006, 2:49am UTC](https://boards.straightdope.com/t/longest-anagram/358666/6 "2006-05-30T02:49:54Z")

</div>

> [@Askance](#):
>
> How could an anagram be anything other than identical length? 😕

In anagramming, 14, for example, doesn’t equal 5+3+6, because one long word is not three short words.

---

<div class="post-metadata">

### Author: ![Sage\_Rat](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sage_rat/32/399_2.png) [@Sage\_Rat](https://boards.straightdope.com/u/Sage_Rat)
#### Post date: [May 30, 2006, 8:55am UTC](https://boards.straightdope.com/t/longest-anagram/358666/7 "2006-05-30T08:55:54Z")

</div>

> [@Majikthise](#):
>
> All of the above words are found in the Linux words file. I’d be interested to see if anyone can guess the simple algorithm I used to generate these.

Well, a **simple** algorithm would be to store all the words in a hash and then go through each trying all the combinations and checking if those exist in the hash. …which sounds a bit time consuming.

A **real** , and still relatively simply method, would be to store a letter count as a string and use that as a key into a hash which contained in each slot a list of the words which hashed to it.

So for instance, dog might go to:

0-0-1-0-0-1-0-0-0-0-0-0-0-1-0-0-0-0-0-0-0-0-0-0-0 (i.e. one ‘d’, one ‘g’, and one ‘o’)

Which will of course also be the key created by ‘god’

From there, it’s just a matter of sorting the contents of your hash.

---

<div class="post-metadata">

### Author: ![Sage\_Rat](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sage_rat/32/399_2.png) [@Sage\_Rat](https://boards.straightdope.com/u/Sage_Rat)
#### Post date: [May 30, 2006, 8:59am UTC](https://boards.straightdope.com/t/longest-anagram/358666/8 "2006-05-30T08:59:24Z")

</div>

> [@Sage Rat](#):
>
> 0-0-1-0-0-1-0-0-0-0-0-0-0-1-0-0-0-0-0-0-0-0-0-0-0

I missed the leading zero. Properly that should be 0-0-0-1-0-0-1-0-0-0-0-0-0-0-1-0-0-0-0-0-0-0-0-0-0-0

---

<div class="post-metadata">

### Author: ![Malacandra](https://avatars.discourse-cdn.com/v4/letter/m/45deac/32.png) [@Malacandra](https://boards.straightdope.com/u/Malacandra)
#### Post date: [May 30, 2006, 1:35pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/9 "2006-05-30T13:35:35Z")

</div>

“Interlaminations” and “Internationalism” are a pair of 16-letter instances.

---

<div class="post-metadata">

### Author: ![ianzin](https://avatars.discourse-cdn.com/v4/letter/i/ed655f/32.png) [@ianzin](https://boards.straightdope.com/u/ianzin)
#### Post date: [May 30, 2006, 2:37pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/10 "2006-05-30T14:37:34Z")

</div>

> [@dauerbach](#):
>
> I’ve been trying to think of a word of greater than four letters that make a single word anagram of identical length. Four is the most I can think of.

I’m wondering if there’s something intended by the OP that we’re all missing. I say this only because it’s hard to believe someone would be unable to find five-letter words that form anagram pairs. I don’t mean any disrespect to **dauerbach** , but you don’t have to be a genius word puzzle geek to notice things like table / bleat, steam / mates, crate / trace and so on. There are lots of very common five-letter words that are anagrams of others. Even six- and seven-letter anagram pairs are not hard to find.

---

<div class="post-metadata">

### Author: ![Sage\_Rat](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sage_rat/32/399_2.png) [@Sage\_Rat](https://boards.straightdope.com/u/Sage_Rat)
#### Post date: [May 30, 2006, 3:16pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/11 "2006-05-30T15:16:55Z")

</div>

> [@dauerbach](#):
>
> I’ve been trying to think of a word of greater than four letters that make a single word anagram of identical length. Four is the most I can think of. Anyone have any ideas?

letters -\> settler -\> trestle  
ideas -\> aides -\> aside

Those appear to be the only two from your post that will anagram out (well besides “single” which goes to “engles” which isn’t a word I know.)

---

<div class="post-metadata">

### Author: ![Majikthise](https://avatars.discourse-cdn.com/v4/letter/m/bb73d2/32.png) [@Majikthise](https://boards.straightdope.com/u/Majikthise)
#### Post date: [May 30, 2006, 3:25pm UTC](https://boards.straightdope.com/t/longest-anagram/358666/12 "2006-05-30T15:25:48Z")

</div>

> [@Sage Rat](#):
>
> Well, a **simple** algorithm would be to store all the words in a hash and then go through each trying all the combinations and checking if those exist in the hash. …which sounds a bit time consuming.
> 
> A **real** , and still relatively simply method, would be to store a letter count as a string and use that as a key into a hash which contained in each slot a list of the words which hashed to it.
> 
> So for instance, dog might go to:
> 
> 0-0-1-0-0-1-0-0-0-0-0-0-0-1-0-0-0-0-0-0-0-0-0-0-0 (i.e. one ‘d’, one ‘g’, and one ‘o’)
> 
> Which will of course also be the key created by ‘god’
> 
> From there, it’s just a matter of sorting the contents of your hash.

That’s pretty close to what I did, except I used a somewhat simpler hash function: simply write the letters of the word in alphabetical order. I now have a wordlist file with 2 columns: first is the “hash,” and column 2 has the actual word. The rows are sorted alphabetically by column 1. Then all I have to do is search for duplicate hashes, filtering out words that are below a threshold length.

Coincidentally, the 2-column word list is also handy for solving the Jumble in the daily paper: Just look up the letters, and the unscrambled word is right there next to it. If you printed the list out, you could even unscramble words without a computer.
