2题
*
**
***
****
*****
3题
1 1 2 3 5
8 13 21 34 55
……
……
我在学习给出讲解更好了
50åå°±ç»ä½ åä¸é¢å§ã
#ï¼/bin/sh
#模æ计ç®å¨
case $2 in
1) sum=$(($1+$3))|echo "$1 + $3=$sum";;
2) sum=$(($1-$3))|echo "$1 - $3=$sum";;
3) sum=$(($1*$3))|echo "$1 * $3=$sum";;
4) sum=$(($1/$3))|echo "$1 / $3=$sum";;
esac
#ï¼/bin/sh
#模æ计ç®å¨
case $2 in
1) sum=$(($1+$3))|echo "$1 + $3=$sum";;
2) sum=$(($1-$3))|echo "$1 - $3=$sum";;
3) sum=$(($1*$3))|echo "$1 * $3=$sum";;
4) sum=$(($1/$3))|echo "$1 / $3=$sum";;
esac
温馨提示:答案为网友推荐,仅供参考