我想让用户输入选择,然后使用 if elif 语句来区分输入。
代码:
read in
if $in = "1"
then
Type="Employee1"
elif $in = "2"
then
Type="Employee2"
elif $in = "3"
then
Type="Employee3"
else
echo "Wrong input"
错误:
./Pay.sh: line 127: 1: command not found
./Pay.sh: line 130: 1: command not found
./Pay.sh: line 133: 1: command not found
Wrong input
请指教谢谢