#!/bin/bash
while read line
do
echo $line
done < filename
cat filename|while read line
do
echo $line
done
逐个获取字串的方法:
wlist="abc def ghi kjl opq"
for w in $wlist
do
echo $w
done
#!/bin/bash
while read line
do
echo $line
done < filename
cat filename|while read line
do
echo $line
done
逐个获取字串的方法:
wlist="abc def ghi kjl opq"
for w in $wlist
do
echo $w
done