DS Unit 2 Part 2
DS Unit 2 Part 2
The linked list where the last node points the header node is called
circular linked list.
}/*end of dequeue*/
void display()
{
if(front==NULL)
printf("\nThe circular list is empty.");
else
{
printf("\nElements in the list are: ");
ptr=front;
do{
printf(" %d",ptr->data);
ptr=ptr->link;
}while(ptr!=front);
}/*end of else*/
}/*end of display*/