Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #checks if speed is 150
- 157 if [[ $2 -eq 150 ]];
- 158 then
- 159 starttime=$SECONDS
- 160 FS=$'n'
- 161 for j in `grep --color=always -iP 'b[^aeious]*[aeiou][^aeious]*K[aeiou]' $1`;
- 162 do
- 163 #Reads the text file in the centre of the screen
- 164 echo " ___________________"
- 165 echo " $j";
- 166 echo " ___________________"
- 167 echo " Speed 150 wpm"
- 168 sleep 0.9;
- 169 clear;
- 170 done
- 171 endtime=$(($SECONDS - $starttime))
- 172 echo "You read $words_read words in $endtime seconds!"
- 173 exit 8
- 174 fi
- #checks if speed is 150
- if [ $2 -eq 150 ] ; then
- words=0
- starttime=$(date +%s)
- FS=$'n'
- for j in $(grep --color=always -iP 'b[^aeious]*[aeiou][^aeious]*K[aeiou]' $1) ; do
- #Reads the text file in the centre of the screen
- echo " ___________________"
- echo " $j";
- echo " ___________________"
- echo " Speed 150 wpm"
- sleep 0.9
- clear
- words=$(( $words + 1 ))
- done
- endtime=$(( $(date +%s) - $starttime ))
- echo "You read $words words in $endtime seconds!"
- exit 8
- fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement