May 25, 2004

[shell] while 讀入檔案表示法

while read i
do
   echo $i
done < file

和下列效果一樣
for i in `cat file`
do
   echo $i
done

Posted by pank at May 25, 2004 05:12 PM
Comments
Post a comment













Remember personal info?