X-Git-Url: http://www2.svjatoslav.eu/gitweb/?p=fifth.git;a=blobdiff_plain;f=doc%2Fcommands%2Fconditio.txt;fp=doc%2Fcommands%2Fconditio.txt;h=0000000000000000000000000000000000000000;hp=18282728a991138635867155d0521da77c38c747;hb=7ad7475c2abf891a92b457339aaa0c20c40634d1;hpb=791dce846c524feca7b344307597c1d1224ba1de diff --git a/doc/commands/conditio.txt b/doc/commands/conditio.txt deleted file mode 100644 index 1828272..0000000 --- a/doc/commands/conditio.txt +++ /dev/null @@ -1,39 +0,0 @@ - Conditionals & loops - ------------------ - -if ( flag -- ) (immideate) - "if 1.. else 2.. then" or - "if 1.. then" construction. Conditional execution. - Performs "1.." if "flag" was true, - elseway performs "2.." if exist. Execution continues after - word "then". - ex: 1 if ." nonzero" else ." zero" then - ->= ( n1 n2 -- result ) true if (n1 = n2) or (n1 > n2) - ex: 5 3 >= if ." first number is greater or equal" then - -<= ( n1 n2 -- result ) true if (n1 = n2) or (n1 < n2) -= ( n1 n2 -- result ) true if n1 = n2 - -do ( count -- ) (immideate) - "do .. loop" construction. Performs ".." "count" times. - In every step "count" is decareased until it is 0. - ex: : test 5 do i .d loop ; - result: 4 3 2 1 0 - -doexit ( -- ) exit from "do .. loop" - -for ( count top -- ) (immideate) - "for .. loop" construction. Performs ".." (top - count) times. - In every step "count" is incareased until it reaches "top" . - ex: : test 4 10 for i .d loop ; - result: 4 5 6 7 8 9 - -forexit ( -- ) exit from "for .. loop" - -until ( -- ) (immideate) - "until .. loop" construction. Performs ".." until flag become - true. False by default. Top of return stack holds flag. - -done ( -- ) exit from "until .. loop" -