All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > General > Word Problems
Academia, defeated, yesterday (Posted on 2015-02-26) Difficulty: 3 of 5
a. What is the longest English word that begins and ends with the same letter?

b. What letters do not provide even one qualifying candidate having this feature?

c. Same as a, but no repeated letters except the first and the last (none of the title's word qualify).

See The Solution Submitted by Ady TZIDON    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer solutions | Comment 2 of 6 |
DefDbl A-Z
Dim crlf$, used(26)

Private Sub Form_Load()
 Text1.Text = ""
 crlf$ = Chr(13) + Chr(10)
 Form1.Visible = True


 Open "\words\words.txt" For Input As #1
 Do
  Line Input #1, l$
  If Left(l$, 1) = Right(l$, 1) Then
    If Len(l$) >= mx Then mx = Len(l$): Text1.Text = Text1.Text & l$ & Str(mx) & crlf
    If Len(l$) >= mx2 And Left(l, 1) <> "s" Then mx2 = Len(l$): Text1.Text = Text1.Text & l$ & Str(mx2) & crlf
  End If
 Loop Until EOF(1)
 Close
 
 Text1.Text = Text1.Text & crlf & crlf
 
 Open "\words\words.txt" For Input As #1
 Do
  Line Input #1, l$
  If Left(l$, 1) = Right(l$, 1) Then
    used(InStr("abcdefghijklmnopqrstuvwxyz", Left(l, 1))) = 1
  End If
 Loop Until EOF(1)
 For i = 1 To 26
  If used(i) = 0 Then
    Text1.Text = Text1.Text & Mid("abcdefghijklmnopqrstuvwxyz", i, 1)
  End If
 Next
 Close
 
 Text1.Text = Text1.Text & crlf & crlf
 
 mx = 0
  Open "\words\words.txt" For Input As #1
 Do
  Line Input #1, l$
  If Left(l$, 1) = Right(l$, 1) Then
   good = 1
   For i = 2 To Len(l) - 1
    If InStr(i + 1, l, Mid(l, i, 1)) > 0 Then good = 0
   Next
   If good Then
    If Len(l$) >= mx Then mx = Len(l$): Text1.Text = Text1.Text & l$ & Str(mx) & crlf
    If Len(l$) >= mx2 And Left(l, 1) <> "s" Then mx2 = Len(l$): Text1.Text = Text1.Text & l$ & Str(mx2) & crlf
   End If
  End If
 Loop Until EOF(1)
 Close


End Sub


finds

Part a.: straightforwardnesses (21 letters), unless its plural nature makes us look askance at it, in which case transformationalist (19 letters) counts as the longest.

The output shows successively better answers, both with and without s ending kept track of separately.

a 1
a 1
aa 2
aa 2
aba 3
aba 3
abaca 5
abaca 5
abaka 5
abaka 5
abasia 6
abasia 6
abdomina 8
abdomina 8
abracadabra 11
abracadabra 11
acciaccatura 12
acciaccatura 12
achlorhydria 12
achlorhydria 12
achondroplasia 14
achondroplasia 14
adenocarcinoma 14
adenocarcinoma 14
adenocarcinomata 16
adenocarcinomata 16
agammaglobulinemia 18
agammaglobulinemia 18
chromolithographic 18
chromolithographic 18
dehydrochlorinated 18
dehydrochlorinated 18
deinstitutionalized 19
deinstitutionalized 19
electroluminescence 19
electroluminescence 19
sanctimoniousnesses 19
semiconsciousnesses 19
sentimentalizations 19
spectrofluorimeters 19
spectrofluorometers 19
spectrofluorometries 20
spectroheliographies 20
straightforwardnesses 21
transformationalist 19

b.: letters not eligible:

jqz

c.: stickhandlers and stylographies (13 letters each), if plurals are allowed, and godfathering (12 letters) if not.

a 1
aa 2
aba 3
abdomina 8
agrypnia 8
alopecia 8
amberina 8
amblyopia 9
ametropia 9
anchoveta 9
androecia 9
apothecia 9
archegonia 10
carbonylic 10
carboxylic 10
coenzymatic 11
cryptogamic 11
cryptogenic 11
cytomegalic 11
cytoplasmic 11
discouraged 11
disgruntled 11
downshifted 11
exhaustible 11
exorbitance 11
explorative 11
godfathering 12
spaceflights 12
speculations 12
stickhandlers 13
stylographies 13


  Posted by Charlie on 2015-02-26 12:07:52
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (2)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2017 by Animus Pactum Consulting. All rights reserved. Privacy Information