| 标题 | 阅读 | 评论 | 转发 | 发布日期 | |
|---|---|---|---|---|---|
| linux的职业方向 | 1009 | 0 | 0 | 2009-03-23 | |
| bash: groupadd: command not found | 1195 | 0 | 0 | 2009-03-23 | |
| 实用技巧:如何更有效率的使用Linux键盘 | 749 | 0 | 0 | 2009-03-23 | |
| Linux能否靠架构取得胜利 | 766 | 0 | 0 | 2009-03-23 | |
| Ubuntu Linux系统下自动启动程序的设置 | 966 | 0 | 0 | 2009-03-23 | |
| 允許Linux的snmp服務被查詢 | 890 | 0 | 0 | 2009-03-23 | |
| 如何判定你是否具备有学习Linux的素质 | 407 | 0 | 0 | 2009-03-23 | |
| gcc新手入門 | 708 | 0 | 0 | 2009-03-23 | |
| 传说中的鸟哥-----------终于看到了 | 1242 | 0 | 0 | 2009-03-23 | |
| CentOS5+mysql+php的配置 | 789 | 0 | 0 | 2009-03-23 | |
| Cdn间隙性故障总结 | 795 | 0 | 0 | 2009-03-23 | |
| 我的linux学习进程 | 1211 | 0 | 0 | 2009-03-23 | |
| Linux 服务器下多网卡的负载均衡 | 1219 | 0 | 0 | 2009-03-23 | |
| 破解没加密的Linux密码 | 795 | 0 | 0 | 2009-03-23 | |
| Linux或Unix下怎样修改系统时间 | 767 | 0 | 0 | 2009-03-23 | |
| Linux下修改系统IP | 992 | 0 | 0 | 2009-03-23 | |
| Linux操作系统下6个应急处理小常识 | 1200 | 0 | 0 | 2009-03-23 | |
| Linux驱动入门 | 1321 | 0 | 0 | 2009-03-23 | |
| linux与win分区格式详解 | 1156 | 0 | 0 | 2009-03-23 | |
| linux网卡驱动程序的编译与安装 | 972 | 0 | 0 | 2009-03-23 |
朋友你好!
我刚开始搞linux,碰到了很多问题,想问你下,希望能帮我解答下。
下面是我的一段shell 程序
#!/bin/sh
while [ 0 ]
do
read score
if [ $score -lt 60 ];then
echo " you must work hard!"
elif [ $score -lt 80 ]
echo " just so so,you should do better"
elif [ $score -le 100 ]
echo ”done well ,keep it "
fi
echo " if you want to contiune press y,else press any key to exit"
read C
if [ $c =y ];then
contiune
else
echo "thanks for coming"
fi
done
运行
$ sh -x test.sh
有个错误提示在第二个if出(if 【 $C =y ]) unary operator expected
是什么原因呀?
我以为是一个shell程序里不能同时出现两个if--then--else语句,可要是不能这样
我要实现程序跳转(也就是查了以个分数等级后,不退出程序还能继续查询第二个)
该用什么方法实现。
小弟在此先行叩谢了。