#!/bin/bash read -p "请输入第一个数:" a read -p "请输入第二个数:" b echo "$a+$b=$[$a+$b]" echo "$a-$b=$[$a-$b]" echo "$a×$b=$[$a*$b]" echo "$a/$b=$[$a/$b]" echo "$a%$b=$[$a%$b]"
#!/bin/bash read -p "请输入第一个数:" a read -p "请输入第二个数:" b echo "$a+$b=$[$a+$b]" echo "$a-$b=$[$a-$b]" echo "$a×$b=$[$a*$b]" echo "$a/$b=$[$a/$b]" echo "$a%$b=$[$a%$b]"