variable
# workfoo=barecho $foo> bar# not workfoo = bar> command not found: fooecho "value is $foo"> value is bar
reserved command
# the name of the script$0# the first-ninth argument that scirpt takes$1-9# the last argument of the previous command$_mkdir testcd $_# get the error code from the previous command$?# get the previous command!!
functions
# mcd.shmcd () {# $1 means the first argument of inputmkdir -p "$1"cd "$1"}# execute this script in our shell and load itsource msc.sh# now you can use the function in msc.sh definedmcd test
