123
-=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- (c) WidthPadding Industries 1987 0|56|0 -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=-
Socoder -> Off Topic -> Dictionary words in a text file

Tue, 24 Apr 2007, 05:47
mike_g
Does anyone know where I can get a text file holding all the words in a dictionary. I have been looking for one for about an hour now but all I have been able to get hold of so far is a dictionary with explanations of the words. I just want the word names, cheers.
Tue, 24 Apr 2007, 05:50
JL235
I have one, but not on this pc. It was given to me for one of my assignments. We had to make a spellchecker, you can have that too if you want.

What are you making?
Tue, 24 Apr 2007, 05:57
Jayenkai
That'd be a "Word List".
Plenty of them, all over the place.

This isn't a simple text list, but it is a nicely formatted list of numbers (which resemble words!) and a bunch of functions ready and willing to check if words are in the list.

Sorted!!

Even does Wildcards

(Um, in Blitz!)

|edit| Duh! Can't remember how to work my own BBCode!! |edit|

-=-=-
''Load, Next List!''
Tue, 24 Apr 2007, 05:59
Blitz3Dman
Ahh, good times, good times, the teacher gives you a pencil, a sharpener, a piece of paper and a dictonary... Back in my day, if you couldn't copy the entire webster's huge dictonary in 5 minutes, it was curtains for you.

good times, good times...



-=-=-
There are 10 kinds of people in this world -

( Insert 16 remarks about to what extent people know hex here )
Tue, 24 Apr 2007, 06:03
mike_g
I was thinking about writing a little prog in C that lets you enter a set of letters, then it finds all the words you can make out of it. Maybe then I could use it in a word game or something. If I could get hold of a copy off you sometime that would be much appreciated

Tue, 24 Apr 2007, 06:09
Jayenkai
Oh.. C++, eh..

Well, it's a bit messier, and probably needs about 10 or so extra arrays in your code, (just hunt for array names, and build them up!) but I'm sure you can figure it out..

The C version
Seems huge, but it shrinks down really well when compiled.. Even fits into a DS's memory

-=-=-
''Load, Next List!''
Tue, 24 Apr 2007, 06:29
JL235
My spellchecker can do that, and it's written in Java so it would be easy to translate. I had to make very clean and well commented too, as it was coursework. Should be very easy to understand.

When I get a chance, I'll upload it.
Tue, 24 Apr 2007, 06:38
Jayenkai
Yeah, that's probably better.. My code's not exactly well commented (Or.. Commented at all!)

-=-=-
''Load, Next List!''
Tue, 24 Apr 2007, 09:43
mike_g
Yeah cool post your spell checker diablo, it would be interesting to see.
Tue, 24 Apr 2007, 16:31
mike_g
Thanks for the wordbank Jay but I gotta say its a bloody mess. Just spent the last hour or so trying to get it to compile. Jay, did you by any chance miss out a header file for with it?

It seems that about every variable is meant to be a global, yet none of them are defined. Nor are the functions defined. The function to get a random number was missing. Theres also two instances of the variable 'len', one where it must be global and another where its being passed into a function. Sorry for all this moaning but i'm giving up now because im bored of the DevC++ ide crashing on me and having to wait ages for each failed compile.

Heres what I got done. Its not a lot, just the declarations, and a random number generator. If anyone wants to finish it off just add it to the wordbank code.

Tue, 24 Apr 2007, 16:37
Jayenkai
I shoved all the definitions into another .c file. Yes, it's a mess, but it worked, so I was happy with that! (Can you tell I prefer Blitz to C!)

Looking over your stuff.

I included the wordbank right at the top, so didn't have to declare the functions.
The single-letter variables are declared at the top of all my C programs, from a->z 'cos I'm too lazy to bother thinking up decent ones, or declaring new ones.
and the PA_ functions are part of PALib (DS Dev library)

-=-=-
''Load, Next List!''
Tue, 24 Apr 2007, 16:49
mike_g
Sorry about that rant. I'm a bit tired and irritable tonight and my compiler keeps crashing on me, so I might need to reinstall it. Thanks all the same
Wed, 25 Apr 2007, 05:45
JL235
Ok, having looked on the other PC I've realised my work isn't on either on them. It's on my own PC which is in Canterbury, so I won't be able to post my code until next week. Sorry.
Tue, 01 May 2007, 11:48
JL235
Here is a link to a file containing 234,937 words. As it's a 2mb text file you might want to right click and 'save as'.

If you want the Spell Checker code, PM or e-mail me and I'll be happy to send it to you. I'm not going to publish the code as the assignment may be used again in the future and I don't want students finding and using my solution.
Tue, 01 May 2007, 11:52
mike_g
Hey thanks for that diablo, its just what I was after
Tue, 01 May 2007, 13:13
Paul
Thx very much
just one thing, what sign is it separating the letters? It only shows up as a square on my pc.
Tue, 01 May 2007, 13:25
Phoenix
Maybe it's \n, the newline character.
Tue, 01 May 2007, 13:39
Paul
yup, just saw that, notepad didn't see that though, tried it in wordpad and there i saw the new lines
thx again for the file and the help