home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Journal 1990 - 1995 / CUJ.iso / image90 / 9006t1f4.pcx (.png) < prev    next >
PC Paintbrush Image  |  1996-01-31  |  75.8 KB  |  714x428  |  4-bit (4 colors)
   ocr: Queue Impiemenation of a queue as a linked data structure If (emptyl)) Operations supported: Queue is empty, point the queue head and tail enqueue(x) place iten X at end of queue at the new iten head return item at head of queue qHead = new; dequeue remove next iten from front of queue gTail = new; empty return true iff queue is enpty Else * Data structures - qHead poiater to the head of queue queue is not empty, insert the iten and point qTail pointer to the tail of queue everything - to new; it A qltem queue nemver structure Alail->next * next pointer to next item on. queue gTail - new; 1 an ...