View Single Post
Old 05-06-2005, 01:43 AM   #1 (permalink)
deepak_kr_mehta
Guest
 
Posts: n/a
implemention of programe

hello sir

create some objects of the string class and put them in a Dequeue some at the head of the deque and some at the tail.Display the contents of the Deque using the foreach() function and a user written display function. Then the search the Dequeue for a particular string using the first That () function display display string that match.Finally remove the all the items from the Dequeue using the getleft() function and display each item.notice the order in which the item are displayed :using getleft(),those inserted on the left(head)of the Dequeue are removed in "last in first out" order while those put on the right side are removed in "first in first out" order. the opposite would be true if getright() were used.