Bash Scripting - Error Handling
Consider this script snippet:
What is the problem if the script always prints "Failed" even when the directory is created?
mkdir test_dir false if [ $? -eq 0 ]; then echo "Created" else echo "Failed" fi
What is the problem if the script always prints "Failed" even when the directory is created?
