hello friends,
i have some problem with the concept of singly link list,,, don't know how to read it backward
pls help
sparsh610 0 Newbie Poster
Recommended Answers
Jump to PostYou do not read singly linked list backward, that is why it is called singly linked. You would basically need to build another singly linked list reversed while reading the list from front to back. The process would be same as not in place reversing the linked list function uses.
Jump to Postlinked lists that can be read backwards are called double liked lists because they have both a next and previous pointers. The previous pointer at the head is NULL so that you can detect the end of the list, and the next pointer at the tail is NULL for the …
Jump to Postif i m not wrong it means , i have to create a reverse link list and then read it , in order to read a link list in backward fashion
No. You understood AD and pyTony correctly (I think), that's what they suggested. But that is certainly …
Jump to PostThere is another approach to this, which would not require you to rebuild the list; however, the technique needed is not that different from that used to reverse the list, so which would be the most useful would depend on the overall goal. In essence, what you would do is …
Jump to Post@Trentacle
so if i use stack as singly linked list i dont travel reverse when i pop it ? even link Click Here
All 22 Replies
TrustyTony 888 ex-Moderator Team Colleague Featured Poster
Ancient Dragon 5,243 Achieved Level 70 Team Colleague Featured Poster
sparsh610 0 Newbie Poster
Ancient Dragon 5,243 Achieved Level 70 Team Colleague Featured Poster
Sokurenko 42 Junior Poster
mike_2000_17 2,669 21st Century Viking Team Colleague Featured Poster
Schol-R-LEA 1,446 Commie Mutant Traitor Featured Poster
Sokurenko 42 Junior Poster
Trentacle 112 Junior Poster in Training
Sokurenko 42 Junior Poster
TrustyTony 888 ex-Moderator Team Colleague Featured Poster
Trentacle 112 Junior Poster in Training
deceptikon 1,790 Code Sniper Team Colleague Featured Poster
Trentacle 112 Junior Poster in Training
Schol-R-LEA 1,446 Commie Mutant Traitor Featured Poster
deceptikon 1,790 Code Sniper Team Colleague Featured Poster
mike_2000_17 2,669 21st Century Viking Team Colleague Featured Poster
deceptikon 1,790 Code Sniper Team Colleague Featured Poster
mike_2000_17 2,669 21st Century Viking Team Colleague Featured Poster
TrustyTony 888 ex-Moderator Team Colleague Featured Poster
sparsh610 0 Newbie Poster
mike_2000_17 2,669 21st Century Viking Team Colleague Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.