Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Loop with negative count

From: lmecir:mbox:vol:cz at: 29-Dec-2006 12:14

Hi Peter, ...
> Ladislav > > That is good news. Will your tests eventually be published? They are no > doubt an excellent document of Rebol's behaviour
I guess that there will be a way how to contribute new tests. (and eventually read the existing ones). Until then here is a specimen FOR test, which passes: [ success: true num: 0 for i 1 10 1 [ num: num + 1 success: i = num and success ] 10 = num and success ] For an illustration here is a FOR test that fails: ; infinite loop tests [ num: 0 for i b: [1] tail b 1 [ num: num + 1 if num > 2 [break] ] num <= 2 ] This is a LOOP test inspired by Tim: [ success: true loop -1 [success: false] success ] -L