Bash Scripting - Variables
What will be the output of this script?
MYVAR=hello readonly MYVAR MYVAR=world echo $MYVAR
MYVAR=hello readonly MYVAR MYVAR=world echo $MYVAR
MYVAR is assigned "hello" and then made readonly. The script then tries to change it to "world".MYVAR remains "hello". The echo command outputs the original value.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions