From: Larry Hazel <lhhazel@otelco.net>
Subject: Re: Non destructive summation of nodes (Linked List/FIFO Queue)
Date: Tue, 01 Jan 2002 20:06:18 -0600
Date: 2002-01-01T20:06:18-06:00 [thread overview]
Message-ID: <3C326B1A.E1209806@otelco.net> (raw)
In-Reply-To: MerY7.24617$Zg2.2575659@news11-gui.server.ntli.net
Another thought is to add each removed element to another queue. So, you've
still got the queue after displaying each element. It just has a different
name.
Liddle Feesh wrote:
>
> Michal suggested:
>
> while not (Queue.Is_Empty_Queue(Queue) ) loop
> Queues.Remove (Element, Queue);
-- Add the removed element to another queue
Queues.Add (Element, Another_Queue);
> Put(Element);
> New_Line;
> end loop;
>
> ------
>
> However, the above basically removes each node whilst 'counting' back the
> values stored in each.
>
Larry
next prev parent reply other threads:[~2002-01-02 2:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-01-01 23:02 Non destructive summation of nodes (Linked List/FIFO Queue) Liddle Feesh
2002-01-02 0:50 ` Larry Hazel
2002-01-02 2:06 ` Larry Hazel [this message]
2002-01-02 2:41 ` James Rogers
2002-01-02 11:17 ` Michal Nowak
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox