variable

do not know why this piece of code does not work

echo "enter input"
read input
if [ $input="abc" ]; then
echo the input is abc
else
echo the input is wrong
fi

thanks for the help

if [ "$input" = "abc" ]; then

The equals sign must be surrounded by spaces. $input must be in quotes to handle the case where there $input is empty.

now it works
thank you so much for the help