The print function is used to print objects in the queue. This function should accept a pointer to an object in the queue as an argument and should generate some output based on that object.
The following is an example of a print function:
long printit(ptr1) void *ptr1; { struct MYSTRUCT *p1; p1 = (struct MYSTRUCT *)ptr1; printf("%d %d %s", p1->myval1, p1->myval2, p1->mystring); }