Positional Parameters When a program is executed with a list of options and arguments, these are passed in as positional parameters. Command examines and determines validity of option/argument.
#!/bin/bash #save this in a file such as arglister.sh # and make it executable, then as follows : # ./arglister.sh one "and two" and a three echo using '$*' for arg in $* do echo $arg done echo "" echo using '"$*"' for arg in "$*" do echo $arg done echo "" echo using '$@' for arg in $@ do echo $arg done echo "" echo using '"$@"' for arg in "$@" do echo $arg done |