POV-Ray : Newsgroups : povray.off-topic : My hypothesis : Re: My hypothesis Server Time
29 Jul 2024 20:17:01 EDT (-0400)
  Re: My hypothesis  
From: Invisible
Date: 6 Sep 2011 04:15:39
Message: <4e65d6ab$1@news.povray.org>
On 05/09/2011 11:19 PM, Darren New wrote:
> On 9/5/2011 14:36, Warp wrote:
>> What happens to the old heap?
>
> It's functional. The old heap is still in x, where you passed it in. Or
> x'. Or something like that.

Actually, x' is the new element you're inserting, not the heap. I didn't 
give the heap itself a variable name at all.

> You would have to say
> newheap := insert 27 oldheap
> or some such. Then the old heap is in oldheap and the new heap is in
> newheap.

Quite.

(Although the actual syntax calls for "=", not ":=", but whatever.)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.