Commit b28bfd11 authored by Roshan Rabinarayan's avatar Roshan Rabinarayan

updated q6

parent 0aed0d46
#!/bin/sh #!/bin/sh
lyrics=$1
cussWords=$2
DONE=false DONE=false
out=""; cp $1 output.txt
until $DONE; do until $DONE; do
read s || DONE=true read s || DONE=true
for words in $s for words in $s
do do
if grep -q "$words" $2
then sed -in s/$words/bleep/gI output.txt
out="$out bleep"
else
out="$out $words"
fi
done done
done < $lyrics done < $2
echo $out
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment