Write a shell script to compare two strings input by the user for equality.
1
Expert's answer
2021-12-11T05:52:04-0500
read -p "Enter a string: " str1
if [ $str1 == "linux" ]
then
echo "linux"
elif [ $str1 == "unix" ]
then
echo "unix"
else
echo "Neither linux nor unix"
fi
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment