in this question i assumed that we need to write a function which takes an
input a queue and function implements the required.
we don't know how the queue is implemented, means we don't know about
structure of the node.
only 2 standard functions of queue enqueue and dequeue are known

On Fri, Jun 10, 2011 at 11:16 PM, scifi <[email protected]> wrote:

> Y do we need to deque and enque the nodes again the problem is similar
> to the node given in the linked list and delete that node.
> solution is :
> copy the next node data to the node to be deleted(ie node holding -ve
> number) and delete the next node.
> in this way order won't be changed.
> Correct me if i am wrong
>
>
> On Jun 10, 3:14 pm, Sangeeta <[email protected]> wrote:
> > write an algo that deletes all negative integers without changing the
> > order of remaining elements of the queue
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 
Sunny Aggrawal
B-Tech IV year,CSI
Indian Institute Of Technology,Roorkee

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to