Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
19
Task/Call-a-function/XLISP/call-a-function.xlisp
Normal file
19
Task/Call-a-function/XLISP/call-a-function.xlisp
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
; call a function (procedure) with no arguments:
|
||||
(foo)
|
||||
|
||||
; call a function (procedure) with arguments:
|
||||
(foo bar baz)
|
||||
; the first symbol after "(" is the name of the function
|
||||
; the other symbols are the arguments
|
||||
|
||||
; call a function on a list of arguments formed at run time:
|
||||
(apply foo bar)
|
||||
|
||||
; In a REPL, the return value will be printed.
|
||||
; In other contexts, it can be fed as argument into a further function:
|
||||
(foo (bar baz))
|
||||
; this calls bar on the argument baz and then calls foo on the return value
|
||||
|
||||
; or it can simply be discarded
|
||||
(foo bar)
|
||||
; nothing is done with the return value
|
||||
Loading…
Add table
Add a link
Reference in a new issue