#3:03 PM 10/29/2004 #Dirk Fretz - dbfretz - Lab 11 #This program shows positional values and associated parameters based on command line input clear #start with a clear screen echo #act as line breaks echo "The positional variable and associated program are: \$0 = <$0>" #Display positional variable & associated program echo echo "The parameter count is: $#" #Display command line parameter count echo echo "These are the parameters: <$@>" #Display command line parameters echo y=1 #set seed for counting up to 9 for x in "$@" #Loop to associate x with each command line variable do #Conditional "do" if [ $y -gt 9 ] #If y > 9, break program then break fi echo \$$y = "<$x>" #Display positional variable & associated command line parameter let y=y+1 #Increment y by 1 done #Loop is finished after y > 9 echo