Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linklist problem

Status
Not open for further replies.

edmorize

Programmer
May 22, 2001
5
AU
I am a newbie of c programming.. I have no idea how to implement a linklist program in c that can read the data from a text file and how can I distinguish whether it is a command like (INSERT, DELETE) or it is an item such as apple, orange and also how can I separate the " ; " that along with each item? Anything is appreciated!!!

Implement a linked list which maintains lexical order of the string data elements. Your program will be driven by an input file (text) which gives the required commands and arguments in the form described below.

Textfile:
INSERT apple; INSERT orange; INSERT pear; INSERT mango; INSERT pawpaw; INSERT banana; INSERT grape; DELETE mango; DELETE apple; INSERT strawberry; INSERT peach; DELETE grape; SNAPSHOT*; INSERT mango; SNAPSHOT; INSERT cherry; QUIT

*SNAPSHOT is a dump of the data values in the list.
 
Ur question is welcome in C forum. Pls post this there.
Regards,
SwapSawe.
 
Yeah the C forum could hook this up for you. However I find it strange that your new to C and this is the project your doing? It sounds like a homework assignment, but a intro C class doesn't start by implementing linked list. Hmmm.

bitwise
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top