473,386 Members | 1,883 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

thesaurus in c

can u pls help me in my project.. considering that u have a textfile then you try to search a word from the file, which i was able to implement, how can i show its synonyms? i got a list of synonyms from project gutenberg but im having a hard time on how to use it well for the word search.
Mar 13 '07 #1
4 2611
Ganon11
3,652 Expert 2GB
You could try using an array of linked lists. Each linked list will hold the original word (as the first element) and any synonyms (anything after the 1st element). The array, then, holds the address of each linked list. As you read your file, you can create a new word, add it to a linked list, then add the rest of the words to the list, and finally put the finished list in the first element of the array, then move on.
Mar 13 '07 #2
lqdeffx
39
The problem with link-lists would be that there would be an excessive amount of memory or storage used. Why, as previously stated:
Each linked list will hold the original word (as the first element) and any synonyms (anything after the 1st element).
which means not only would there be a potentially a significant amount of redundancy but new memory address for each of those words. Not to mention what that link-list would look like after a few hundred words. As always, there are lots of ways of doing things, I suggest researching associative arrays such as maps, coding-wise will be much easier to develop and maintain.
Mar 13 '07 #3
Ganon11
3,652 Expert 2GB
Using a map, I'd assume you'd use the word as the key and an array/list/other container of words as the value, which would still result in some of the same problems as you listed above.
Mar 13 '07 #4
lqdeffx
39
yes but using maps for example, will result in less coding, easier implamentation through this massive container. it could even allow someone to be creative and only load certain ranges of words and leave the rest in a file. creating a link-list and iterating through memory addresses can be time consuming. that is all.
Mar 13 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Jaffa | last post by:
hi all, i'm currently designing a search engine. I'd like certain keywords to have affiliated synonyms listed so that I can find out which keywords are symantically related to each other. Is...
0
by: Melody Droid | last post by:
I recently made some conceptual breakthroughs regarding the interval permutation pre-sorting and the pitch-class-set/scale post-sorting aspects of my envisioned symmetrical melody thesaurus...
3
by: Jason | last post by:
Is it possible to connect and asp page to the Microsoft Office Thesaurus? I would like to be able to pass a word to it and get back all of the synonyms as either a string, array, or collection.
1
by: Hans Malherbe | last post by:
I would like to access the Word thesaurus from a .NET WinForm application if the client has Microsoft Word installed. Is it possible? I could not find anything in the Office XP help.
2
by: hammad | last post by:
I had made a .NET Application that use microsoft Word thesaurus using msword file when i made windows application it works well but when i try web application it make exception that i have no...
3
by: Marc | last post by:
Hi everyone, I'm trying to build a Thesaurus. In my thesaurus i've created the following tables: terms, btnt (broader terms/narrower terms), rt (related terms) The structures of the tables...
3
by: moondaddy | last post by:
I'm looking for a thesaurus tool I can use in an application. I was hoping it could be a web service where my app could submit a work and get a list of results back which my code could use. any...
8
by: johnerics | last post by:
Hi Everybody! Hoping that every body would be fine at this group. I am learning c sharp. Please, if anybody can make this program, i would be highly obliged. Implement a thesaurus (a...
0
by: Piero 'Giops' Giorgi | last post by:
Hi! I have the DB, now with about 100 Million rows (Going strong!!!) One question... I'm using Thesaurus search (COOL!!!) for names, (Rebecca, Reba, Becky, Becca....) to query for nicknames...
0
by: Calvin Spealman | last post by:
Sounds like you might want to read up on RDF On Tue, Aug 12, 2008 at 10:41 AM, Benjamin Michiels <benjamin.michiels@gmail.comwrote: -- Read my blog! I depend on your acceptance of my...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.