Question #317653

Write Linux Shell script to display current working directory.  


Expert's answer

echo "The current working directory: $PWD"
echo "The previous current working directory: $OPLDPWD"
_cwd="$PWD"
 
## use pwd command ##
_mydir="$(pwd)"
 
## or ##
_mydir="`pwd`"
 
echo "My working dir: $_mydir"

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS