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

 Synonyms (Posted on 2019-07-01)
Take a 7-letter word. Remove the first 2 letters. Reverse the last 2 letters. Then, add SE at the end to get a synonym of the original word. What is it?

 No Solution Yet Submitted by Math Man No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
 computer-aided solution | Comment 1 of 3
DefDbl A-Z
Dim crlf\$

Text1.Text = ""
crlf\$ = Chr(13) + Chr(10)
Form1.Visible = True
DoEvents

w1\$ = Space(7)
Open "\words\words7.txt" For Binary As #1
Do
Get #1, , w1
If EOF(1) Then Exit Do
w2\$ = Mid(w1, 3, 3) + Mid(w1, 7, 1) + Mid(w1, 6, 1) + "se"
If isWord(w2) Then
Text1.Text = Text1.Text & w1 & "   " & w2 & crlf
End If
DoEvents
Loop Until EOF(1)

Text1.Text = Text1.Text & " done"
End Sub

Function isWord(w\$)
n = Len(w\$)
w1\$ = Space\$(n)
Open "c:\words\words" + LTrim\$(Str\$(n)) + ".txt" For Binary As #2
l = LOF(2) / n
low = 1: high = l
Do
middle = Int((low + high) / 2)
Get #2, (middle - 1) * n + 1, w1\$
If w1\$ = w\$ Then isWord = 1: Close 2: Exit Function
If w1\$ < w\$ Then low = middle + 1 Else high = middle - 1
Loop Until low > high
isWord = 0
Close 2
End Function

finds

`coconut   contusecrimper   impreselaconic   conciseobconic   concisewhimper   imprese`

of which LACONIC and CONCISE could count as synonyms.

 Posted by Charlie on 2019-07-01 09:25:09

 Search: Search body:
Forums (0)