# Longest word with adjacent letters on a keyboard

What is the longest English word you can type using only letters that are adjacent on a QWERTY keyboard?

You can start anywhere and then either repeat the previous letter or move to an adjacent one.

For convenience of those who don't have a QWERTY keyboard, it looks like this.

 ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┐
| Q | W | E | R | T | Y | U | I | O | P |
└─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┘
| A | S | D | F | G | H | J | K | L |
└─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴───┘
| Z | X | C | V | B | N | M |
└───┴───┴───┴───┴───┴───┴───┘


I found this puzzle on the Internet and I don't have a definitive solution.

• A giant game of boggle anyone? – Aggie Kidd Apr 1 '15 at 16:05
• I find it interesting that all the answers so far rely entirely on letters typed with the left hand. This is likely due to the more common vowels being on that side as well as the many suffixes that can be tacked using only E, S, and D. This might be an interesting question for right-hand only letters. – Engineer Toast Apr 1 '15 at 16:59
• Is the same key considered 'adjacent'? IE: if I type 'ERRED' have I made a mistake (heh heh, see what I did there?) because R is not adjacent to R? – Wolfman Joe Apr 1 '15 at 18:01
• @WolfmanJoe it's specified in the question, although I admit it took me a second reading to notice it. – Joffan Apr 1 '15 at 18:02
• Too bad I missed april 1st, or i'll answer lolololololololololololololololololololololololololol... – Alex Apr 2 '15 at 16:47

## 7 Answers

I liked Engineer Toast's idea of finding the longest word you could type with right-hand only letters, so I found those as well.

These words come from my computer's /usr/share/dict/words file, you can decide for yourself which words count as English.

## All keys

(10, 'desertress')
(10, 'assertress')
(9, 'redresser')
(8, 'kolokolo')
(8, 'assessee')

## Left keys

(10, 'desertress')
(10, 'assertress')
(9, 'redresser')
(8, 'assessee')
(8, 'assessed')

## Right keys

(8, 'kolokolo')
(6, 'pookoo')
(6, 'polloi')
(6, 'lollop')
(5, 'plook')

I used the following code to come up with this answer:

LEFT_KEYS = {
'Q':['Q', 'W', 'A'],
'W':['W', 'Q', 'A', 'S', 'E'],
'E':['E', 'W', 'S', 'D', 'R'],
'R':['R', 'E', 'D', 'F', 'T'],
'T':['T', 'R', 'F', 'G', 'Y'],
'A':['A', 'Q', 'Z', 'W', 'S'],
'S':['S', 'W', 'A', 'Z', 'X', 'D', 'E'],
'D':['D', 'E', 'S', 'X', 'C', 'F', 'R'],
'F':['F', 'R', 'D', 'C', 'V', 'G', 'T'],
'G':['G', 'T', 'F', 'V', 'B', 'H', 'Y'],
'Z':['Z', 'A', 'S', 'X'],
'X':['X', 'S', 'Z', 'D', 'C'],
'C':['C', 'D', 'X', 'F', 'V'],
'V':['V', 'F', 'C', 'B', 'G'],
'B':['B', 'G', 'V', 'N', 'H']
}

RIGHT_KEYS = {
'Y':['Y', 'T', 'G', 'H', 'U'],
'U':['U', 'Y', 'H', 'J', 'I'],
'I':['I', 'U', 'J', 'K', 'O'],
'O':['O', 'I', 'K', 'L', 'P'],
'P':['P', 'O', 'L'],
'H':['H', 'Y', 'G', 'B', 'N', 'J', 'U'],
'J':['J', 'U', 'H', 'N', 'M', 'K', 'I'],
'K':['K', 'I', 'J', 'M', 'L', 'O'],
'L':['L', 'O', 'K', 'P'],
'N':['N', 'H', 'B', 'M', 'J'],
'M':['M', 'J', 'N', 'K']
}

ALL_KEYS = LEFT_KEYS.copy()
ALL_KEYS.update(RIGHT_KEYS)

def adjacent(keyset, word):
lastletter = None
for letter in word.upper():
if lastletter:
if not letter in keyset.get(lastletter, []):
return False
lastletter = letter
return True

def read_word_list():
with open('/usr/share/dict/words') as wordfile:
return [w.strip() for w in wordfile.readlines() if len(set(w.strip())) > 1]

WORDS = read_word_list()
ADJACENT_WORDS = []
for WORD in WORDS:
if adjacent(ALL_KEYS, WORD):
ADJACENT_WORDS.append((len(WORD), WORD))

for WORD in sorted(ADJACENT_WORDS)[-5:]:
print WORD
• "desertress" is such a common word. – immibis Apr 2 '15 at 6:12
• @immibis So you don't employ a desertress from Kolokolo to stand out from the hoi polloi? Mine is quite an assertress. – Philipp Apr 2 '15 at 10:52
• How about the even more common plural, "desertresses"? – EagleV_Attnam Apr 2 '15 at 12:37

I get 9 letters:

REDRESSES/REDRESSED

For non-standard words, regarding extinct words and new coinages with equal caution... 11 letters? 14? 16?

I've seen usage of "freedressing" (without regard to gender rules) so presumably someone who does this is a FREEDRESSER (11 letters). Of course, then specifying gender for such a person - a FREEDRESSERESS - might well be objectionable, so they might complain "I can't believe you FREEDRESSERESSED me!"

• It's not often that I lol on StackExchange. – Bob Jansen Apr 2 '15 at 19:26

FREEWEED

The best solution I can think of.

• Umm, but that would be two words which is not an answer to the question... – Len Apr 2 '15 at 8:23
• Your name, your answer, laughing too hard! – leoll2 Apr 2 '15 at 9:59
• Not to be pedantic but by this logic, you forgot about FREEWEEDS and FREEWEEDER – adamwong246 Apr 2 '15 at 21:48

ASSESSED/ASSESSES

is the longest I can come up with.

• 8 letters counted – hildred Apr 1 '15 at 18:04

## 10 LETTERS

I found one with 10 letters but I can't find it in the standard dictionaries. It seems to be an older English word as the modern version drops the gender-specific bit.

DESERTRESS

Otherwise, the 9 letter versions already noted are the longest I can find.

## 12 LETTERS

Or, as pointed out in by EagleV_Attnam in a comment on mark's post, here's a 12 letter option that should have been obvious:

DESERTRESSES

• Hey, if you're going to go that way, why not "dessertresses" - that would clearly be female experts in sweet baked goods :D. – neminem Apr 2 '15 at 17:34
• @neminem I'm all for silly comments despite some SE users who are against such nonsense. As I pointed out, I couldn't find either word in a dictionary. I found references to "desertress" in old books and in translation dictionaries and the "-es" was a logical extension of that. I can't find any references to "dessertress" except for the name of a blog. You could argue that, if one were to create another blog with the name "dessertress" then there would be multiple "dessertresses" in the blogosphere. However, that could be expanded to any string whatsoever as it is a made up name. – Engineer Toast Apr 2 '15 at 17:40

I got the following

seesawed
dessert

edit:

reseesawed, but I am not sure if that is a word or not.

stewardesses (12 letter) Hope to contribute more.

• This is the 3rd time this answer has been given. The previous 2 answers were deleted because the question asks for adjacent keys with no consideration of left or right hand. It seems that this answer should not be deleted to allow others to see that it has already been provided. – Len Apr 4 '15 at 7:04
• How do you expect us to know if it was deleted and never added? In any case, I will have the post retained to avoid any such future posts. – thepace Apr 5 '15 at 8:30

## protected by Community♦Apr 3 '15 at 15:35

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?