how to delete every 3rd node in a circular linked list? After deleting that node, the node is continued to count from the node and again deleting the 3rd node?
Do u have any ideas?
swarnnim 0 Newbie Poster
Recommended Answers
Jump to PostTo move through a linked-list, you will need an iterator. In your case of deleted every third node, simply use a counter which will increment after traversing each node. Delete the current node when your counter reaches the value 3. Then reset your counter to 1 upon iterating to the …
All 3 Replies
Reply to this topic 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.