Word Search
Posted
#1
(In Topic #1938)
Guru


WordSearch-0.0.1.tar.gz
Posted
Administrator

I just downloaded it and looking forward to checking it out later today. I'll report back my adventures.
Posted
Expert

Where did you get the word list from ?
I've tried this with the idea that I could use other language dictionaries at some point.
Private Function GetRandomWord() As String
Dim TmpStr As String
Dim NewWord As Boolean = False
Dim ShellParam As String
Dim DictWordCount As Integer = 101000
Dim DictionaryName As String = "american-english"
'Dim DictionaryName As String = "british-english"
Tlb_ScoreBoard.Text = "Searching for word"
Repeat
ShellParam = "awk -v lineno=" & Str(Rand(1, DictWordCount)) & " 'lineno==NR{print;exit}' /usr/share/dict/" & DictionaryName
Shell ShellParam To TmpStr
TmpStr = LCase(TmpStr)
TmpStr = Replace(TmpStr, "'s", "") ' Many of the words in the dictionary have a plural suffix
TmpStr = Replace(TmpStr, "\n", "") ' Remove the 'new line' characters
If Not UsedWords.Exist(TmpStr) Then NewWord = True
If ((Len(TmpStr) < WaterDropLengthMin) Or (Len(TmpStr) > WaterDropLengthMax)) Then NewWord = False ' This sets up checking if the word length is between specific sizes ie > 4 and < 8
Until NewWord
UsedWords.Add(Str(UsedWords.Count + 1), TmpStr) ' UsedWords is a standard collection to ensure that I don't get double ups.
Return TmpStr
End
Cheers - Quin.
I code therefore I am
I code therefore I am
Posted
Guru


Where did you get the word list from? said
Hi Quin,
It was a long time ago when I downloaded this list, and I don't remember where I got it from, but a quick Google came up with this: - Dictionaries
Posted
Expert

I've collected some text file lists that I've discoverred over the years. Like you, I can't remember where from and if you or anybody else is interested I'll post them up.
- Male first names (2,943)
- Female first names (5,001)
- International surnames (13,460)
- International currency codes.
Cheers - Quin.
I code therefore I am
I code therefore I am
1 guest and 0 members have just viewed this.

