my $wordlist = 'wordlist.txt'; if(! -s $wordlist) { print "File is empty\n"; exit 0; } else { # your code goes here }
In reply to Re: Testing if a .txt file contains any data
by gpapkala
in thread Testing if a .txt file contains any data
by sigmaaa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |