#!/bin/bash#Project 5/2 echo "test1"if [[ -n $5 ]]then echo "test2" if [[ -z "$6" ]] then echo "test3" echo "$1 $2 $3 $4 $5 $((($1+$2+$3+$4+$5)/5))" else echo "test4" echo "You have entered over 5 values" fiecho "test5"else echo "test6" echo "Please enter 5 values"fiecho "test7"Supposed to accept only 5 values from command line and then output them and average them. It currently gives retarded errors that make no sense [Edited on May 10, 2010 at 8:20 PM. Reason : @#)(* - tech talk. sorry]
5/10/2010 8:20:26 PM
try rebooting
5/10/2010 8:21:16 PM
plz to fix sash bcript
5/10/2010 8:23:50 PM
lol, thanks for the useless responses... where the cops mods when you need them?
5/10/2010 8:26:45 PM
#!/bin/bashif [ $# -ne 5 ]; then echo "Please enter 5 values"else echo "$(( ($1 + $2 + $3 + $4 + $5)/5 ))"fi
5/10/2010 8:46:26 PM
back ticks homey
5/10/2010 8:51:42 PM