|
|
|
local varname
local varnamelist
(local varname1 varname2 ...)
command. Accepts as inputs one or more words, or a list of words. A variable is created for each of these words, with that word as its name. The variables are local to the currently running procedure. Logo variables follow dynamic scope rules; a variable that is local to a procedure is available to any subprocedure invoked by that procedure. The variables created by LOCAL have no initial value; they must be assigned a value (e.g., with make) before the procedure attempts to read their value.
Examples:
to proc local [a b c] a=1234 b=[Hallo World!] c={1 2 3} (pr a b c) end ;proc defined proc ;1234 Hallo World! {1 2 3} a ; I don't know how to a b ; I don't know how to b c ; I don't know how to c |
|
|
|