POV-Ray : Newsgroups : povray.general : a really dumb mistake : Re: a really dumb mistake Server Time
26 Apr 2024 00:19:36 EDT (-0400)
  Re: a really dumb mistake  
From: Kenneth
Date: 25 Aug 2017 13:40:05
Message: <web.59a06050d9dfcaae883fb31c0@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> clipka <ano### [at] anonymousorg> wrote:
>
> > Challenge accepted ;)
> >
> > #declare MY_VALUE = 10;
> > #for(C,1,19)
> >   #debug concat("\n","My Value = ",str(MY_VALUE,1,0),"\n")
> >   #declare MY_VALUE = 43-MY_VALUE;
> > #end
>
> I will have to check this out to see what it does...
>

Same here! At first appearance, it doesn't seem like it would work at all. But
it DOES work! Yes, devilishly clever.

Hmm, let's see...

1) MY_VALUE starts at 10
2) 1st #debug = 10
3) MY_VALUE changes to (43 - 10) = 33
4) 2nd #debug = 33
5) MY_VALUE changes to (43 - 33) = 10
6) 3rd #debug = 10
7) MY_VALUE changes to (43 - 10) = 33
8) 4th #debug = 33

....ETC...

Magical!


Post a reply to this message

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