Circular linked lists do not have ends. While traversing the circular linked lists we should be careful; otherwise we will be traversing the list infinitely.
Note that unlike singly linked lists, there is no node with NULL pointer in a circularly linked list.
Usefulness of Circular Linked List :
For example, when several processes are using the same computer resource (CPU) for the same amount of time, we have to assure that no process accesses the resource before all other processes do (round robin algorithm).
Insertion Deletion and Printing content of CLL - See Example - 3.CircularLinkedList.cpp
Note that unlike singly linked lists, there is no node with NULL pointer in a circularly linked list.
Usefulness of Circular Linked List :
For example, when several processes are using the same computer resource (CPU) for the same amount of time, we have to assure that no process accesses the resource before all other processes do (round robin algorithm).
Insertion Deletion and Printing content of CLL - See Example - 3.CircularLinkedList.cpp
No comments:
Post a Comment