added the command  WC -l

to count the number of lines before deletion  uncommented at the end because of errors