Following is the function to traverse the Queue:
void display() { struct node *ptr; ptr=front; printf("Queue is : \n"); while(ptr!=NULL) { printf("%d ",ptr->data); ptr=ptr->next; } }