>> i: 999 loop 300 [ print next form i: i + 1 ]
000
001
002
003
004
005

On 10/5/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Glenn:
>
> >  I'm trying to do this (Ruby):
>
> I guess the first bit you are okay with: running a loop:
>
> for n 0 399 1 [print n]
>
> It's that fixed-length with leading zeroes you want, yes?
>
> Sadly, there is no C-style printf (or even VB- or Cobol-style picture)
> formatting available as standard in REBOL......Still waiting for someone =
to write it
> :-)
>
> Meanwhile, two suggestions:
>
> Do it by hand:
>
>  for n 0 399 1 [loop 3 - length? form n [prin "0"] print n]
>
> Get an assist from align.r in the Library:
>
> http://www.rebol.org/cgi-bin/cgiwrap/rebol/download-a-script.r?script-nam=
e=3Dali
> gn.r
> for n 0 399 1 [print replace/all align/right n 3 " " 0]
>
> Sunanda
> --
> To unsubscribe from the list, just send an email to
> lists at rebol.com with unsubscribe as the subject.
>
>


--
Graham Chiu
-- 
To unsubscribe from the list, just send an email to 
lists at rebol.com with unsubscribe as the subject.

Reply via email to