Nilesh Chakraborty wrote: > Hi all, > > While learning the C language, the most tough part to me, is, "Linked > Lists" - oh! I just can't understand that thing. Could anyone, > including Mr. Hruska, help me out? Any links/guidance would be > appreciated. > > Thanks, > Regards, > Nilesh C
How good are you with pointers? A linked list depends heavily on pointers. You typically have a chunk of data and a pointer (or two*). The pointer points at the next chunk of data, which also is associated with a pointer that points at the next chunk of data...and so on. Perhaps a visual picture can help: Memory is an ocean. The chunks of data are islands in the ocean. The pointers are bridges between the islands. An island can only connect to two other islands. You might want to brush up on your knowledge of pointers before delving into linked lists. You really should be using C++ - linked lists are easier and the STL already has a generic templated implementation instead of rolling your own. -- Thomas Hruska CubicleSoft President Ph: 517-803-4197 *NEW* MyTaskFocus 1.1 Get on task. Stay on task. http://www.CubicleSoft.com/MyTaskFocus/
