![]() |
|
#1
|
|||
|
|||
How to do word comaparison in C++ ?I have this question. I have to find a word in the give file and also synonyms of that word in the file. For example, when I find the word "change", I should also be able to find words like "alter", "changing" etc. Any suggestions?
|
|
#2
|
||||
|
||||
|
Quote:
__________________
Age is unimportant -- except in cheese |
|
#3
|
||||
|
||||
|
or a hash table.
__________________
When you say "I wrote a program that crashed Windows," people just stare at you blankly and say "Hey, I got those with the system, for free." Linus Torvalds |
|
#4
|
||||
|
||||
|
Quote:
i have a assignment almost similar what u question here not sure is it same as ur 1 but the code not effect , no hash table just store in vector and compare only if u want u can take a look __________________
challenges are make life interesting, overcome them is make life meaningful. |
|
#5
|
||||
|
||||
|
Sorry, tay, I don't think that's a valid solution.
__________________
-Aaron |
|
#6
|
|||
|
|||
|
i don't get what exactly mail_as wanna do, so i've nothing to say for now. mail_as pls explain a bit more...
|
|
#7
|
|||
|
|||
|
My questions was to do create a search algorithm. I have an input data file and the word to be searched is accepted from the user (change). As and when I search the word in the input file, I also needed to search words with same meaning. So, now I not only search the word change but also words like changes, changing, alter and so one.
Max Payne - What exactly is a hash table? |
|
#8
|
||||
|
||||
|
Quote:
Hash table is a data structure like linked list but it has different methods. I had used hash table before to make a English-Malay dictionary before for my school project and thats a long time ago, I don't even remember how it work. Hmm, its just a suggestion, take alook at the data structure books, you may find something. Ahh, if I'm not mistaken, its a stack of linked list. Somebody correct me if i'm wrong. For my project, each stack node contains the English word and the linked list of the corresponding stack node contains list of word in Malay which is similar to the Englist word, so I can do a search for English-Malay dictionary. __________________
When you say "I wrote a program that crashed Windows," people just stare at you blankly and say "Hey, I got those with the system, for free." Linus Torvalds |
|
#9
|
||||
|
||||
|
Quote:
Kind of a lame description... When you add something to a hash table you obtain a number from the key value (person's name) to be added to the table. One way is to add the character values mod 1000. This give you an index into the table. Into that index position goes the data record for the person. You will probably get collisions (index values already used) so you further massage the index by maybe adding 13 until you hit an open position. Then when looking for that value again, just repeat the above to get the same index and there's your data. __________________
Age is unimportant -- except in cheese |
|
#10
|
||||
|
||||
|
Quote:
I feel ashamed __________________
When you say "I wrote a program that crashed Windows," people just stare at you blankly and say "Hey, I got those with the system, for free." Linus Torvalds |
Recent GIDBlog
Belkin Laptop Cooler by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| testing word file "need help" | alexandro | C Programming Language | 2 | 03-Jun-2004 14:38 |
| word finder (there are problems) | small_ticket | C Programming Language | 0 | 14-May-2004 15:09 |
| coding a word with a givin factor | funnyf | C++ Forum | 2 | 13-Jan-2004 08:32 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The