forked from ground/ground
Command line arguments
This commit is contained in:
12
tests/args.grnd
Executable file
12
tests/args.grnd
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/usr/bin/env ground
|
||||
stdlnout "Program args: "
|
||||
getlistsize *args &argsSize
|
||||
set &counter 0
|
||||
@loopstart
|
||||
equal $counter $argsSize &bool
|
||||
if $bool %end
|
||||
getlistat *args $counter &item
|
||||
stdlnout $item
|
||||
add 1 $counter &counter
|
||||
jump %loopstart
|
||||
@end
|
Reference in New Issue
Block a user