RosettaCodeData/Task/Variadic-function/Euler-Math-Toolbox/variadic-function.euler

16 lines
195 B
Plaintext

>function allargs () ...
$ loop 1 to argn();
$ args(#),
$ end
$endfunction
>allargs(1,3,"Test",1:2)
1
3
Test
[ 1 2 ]
>function args test (x) := {x,x^2,x^3}
>allargs(test(4))
4
16
64