Summaries/Courses/Linux_and_Bash_for_Data_Eng.../if-else.sh

13 lines
234 B
Bash
Executable File

#!/bin/sh
#
echo "What food do you like?"
read FOOD
if [ "$FOOD" = "Apple" ]; then
echo "Eat yogurt with your ${FOOD}"
elif [ "$FOOD" = "Milk" ]; then
echo "Eat Cereal with your ${FOOD}"
else
echo "Eat your ${FOOD} by itself"
fi