首页 > 代码库 > while

while

while.until.for

break退出循环

continue提前进入下一轮循环


无限循环while特殊用法一:

while :; do

break

done


while特殊用法二:

while read LINE;do


done < /path/to/somefile


unitl bash -n $1 &>/dev/null ;do

 read -p "sytax error,[qQ]exit,others vim" CHOISE

 case $CHOISE in

 q|Q)

    break

     ;;

  *)

    vi $1

     ;;

  esac

done

   

while