Question: Consider the following shell script: echo - e What is your favorite color? - - > c read REPLY if [ $REPLY

Consider the following shell script:
echo -e "What is your favorite color?-->\c"
read REPLY
if ["$REPLY" = "red" o "$REPLY" = "blue" ]
then
echo "The answer is red or blue."
else
echo "The answer is not red nor blue."
fi
What would be displayed if a user executes this shell script and answers Blue when prompted?
Question options:
The answer is red or blue.
The answer is not red nor blue.
The code would cause an error.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!