POV-Ray : Newsgroups : povray.beta-test : while bug ? : Re: while bug ? Server Time
30 Jul 2024 18:20:41 EDT (-0400)
  Re: while bug ?  
From: Anders K 
Date: 10 Oct 2001 08:59:42
Message: <3bc4463e$1@news.povray.org>
> #local i=0;
> #while (i<1)
>   #debug concat(str(i,0,2),"\n")
>   #local i=i+0.1;
> #end

Try

#local i = 0;
#while (i < 10)
  #debug concat(str(i/10, 0, 2), "\n")
  #local i = i + 1;
#end

Since there is no round off error with adding integers.


Post a reply to this message

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