at:tutorial:basic
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Next revisionBoth sides next revision | ||
at:tutorial:basic [2007/04/05 09:58] – * elisag | at:tutorial:basic [2007/04/05 09:59] – elisag | ||
---|---|---|---|
Line 78: | Line 78: | ||
< | < | ||
>def counter := 0 | >def counter := 0 | ||
- | >> 0 | + | >>0 |
> def inc() { counter := counter + 1} | > def inc() { counter := counter + 1} | ||
>>< | >>< | ||
- | > inc() | + | >inc() |
>>1 | >>1 | ||
</ | </ | ||
Line 113: | Line 113: | ||
</ | </ | ||
- | When the //sum// function is called, the arguments are passed to the function in a table called //args// which can also be modified inside the body of the function. An alternative definition of the function | + | When the //sum// function is called, the arguments are passed to the function in a table called //args// which can also be modified inside the body of the function. An alternative definition of the //sum// function |
< | < | ||
>def sum(a, b, @rest){ { | >def sum(a, b, @rest){ { |
at/tutorial/basic.txt · Last modified: 2020/02/09 22:05 by elisag