标签:shell 参数
#!/bin/bash
name=$1
old=$2
if [[ $# -ne 2 ]];then
echo "the test must input 2 nu!!"
echo $#
exit 0
fi
echo "my name is ${name}!"
echo "i‘m ${old} yeas old!"
if [[ ${old} <30 ]];then
echo "you are so yunng!"
else
echo "so old!"
fi
标签:shell 参数
原文地址:http://chicozy.blog.51cto.com/8521389/1762053