PROGRAM
echo "Enter a filename"
read file
grep -v '^$' $file > gfl
lc=`grep -i -v -c [aeiou] gfl`
echo "Number of lines that do not contain any vowels are: $lc"
read file
grep -v '^$' $file > gfl
lc=`grep -i -v -c [aeiou] gfl`
echo "Number of lines that do not contain any vowels are: $lc"
OUTPUT
Enter a filename
fibt
Number of lines that do not contain any vowels are: 0
fibt
Number of lines that do not contain any vowels are: 0
Enter a filename
file3
Number of lines that do not contain any vowels are: 3
file3
Number of lines that do not contain any vowels are: 3
No comments:
Post a Comment