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

Home > General > Word Problems
From product to town (Posted on 2015-04-10) Difficulty: 4 of 5
If Mieleeke were a name of a city in Europe
then by erasing 4 e’s we would get a word Milk.

Find an edible product such that by inserting four identical letters
into its name we get a name of an European city.

See The Solution Submitted by Ady TZIDON    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution computer assisted solution | Comment 1 of 2
The program uses a list of European cities from Wikipedia and looks for entries with 4 or more occurrences of any given letter:

DefDbl A-Z
Dim crlf$

Private Sub Form_Load()
 Text1.Text = ""
 crlf$ = Chr(13) + Chr(10)
 Form1.Visible = True
'  ChDir "\VB5 projects\flooble"

  Open "cities of europe.txt" For Input As #1
    Line Input #1, l$
    l$ = LCase$(l$)
    For i = 1 To 26
     c$ = Mid("abcdefghijklmnopqrstuvwxyz", i, 1)
     ct = 0
     For j = 1 To Len(l$)
      If Mid(l, j, 1) = c Then ct = ct + 1
     If ct >= 4 Then
      Text1.Text = Text1.Text & l$ & "   " & c & crlf
     End If
    Next i
  Loop Until EOF(1)
 Text1.Text = Text1.Text & "done" & crlf

End Sub

It finds:

 stuttgart   t
 saint-denis, reunion   n
 stara zagora   a
 saint-denis, seine-saint-denis   e
 saint-denis, seine-saint-denis   i
 saint-denis, seine-saint-denis   n
 saint-denis, seine-saint-denis   s
The edible word is sugar. With the addition of 4 t's it becomes Stuttgart. 

  Posted by Charlie on 2015-04-10 11:07:50
Please log in:
Remember me:
Sign up! | Forgot password

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

Copyright © 2002 - 2019 by Animus Pactum Consulting. All rights reserved. Privacy Information