Chinaunix首页 | 论坛 | 博客
  • 博客访问: 848773
  • 博文数量: 156
  • 博客积分: 6553
  • 博客等级: 准将
  • 技术积分: 3965
  • 用 户 组: 普通用户
  • 注册时间: 2010-06-22 18:36
文章存档

2012年(3)

2011年(43)

2010年(110)

分类: LINUX

2010-10-03 12:41:26

#!/bin/sh 
echo "Input date with format yyyy mm dd:\c"
read year month day
echo "Today is $year/$month/$day, right"
echo "press enter to confirm and continue\c"
read a
echo "I know the date, bye"
 
注释:
#!/bin/sh   指定解析shell的类型,sh为传统shell,bash为默认使用的shell
 \c这个转义字符表示,不换行,只能使用与sh类型的shell
阅读(946) | 评论(0) | 转发(1) |
给主人留下些什么吧!~~