code to display linked list:
for (Node *cur = head; cur != NULL; cur = cur->next)
cout << cur->item << endl;
in the header file:
struct Node
{ int item;
Node *next;
};
It will declare a new pointer called cur, set it equal to head, and keep going until cur = null (the end of the linked list). And each time it sets cur to the next item then prints it.