Its simple. next if ($line =~ /^\s*$/);
Mallik. -----Original Message----- From: Christopher Spears [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 14, 2004 11:14 AM To: [EMAIL PROTECTED] Subject: regexp for a blank line I have to write a script that processes text in a file. The text includes lots of blank lines. How can I tell Perl to skip the lines? I thought maybe something like: next if ($line =~ /\s+/); However, what if the line simply happens to have more than one whitespace. Even a sentence has whitespace between the words! Or maybe the line is idented! ===== "I'm the last person to pretend that I'm a radio. I'd rather go out and be a color television set." -David Bowie "Who dares wins" -British military motto "The freak is the norm." - "The Infernal Desire Machines of Dr. Hoffman" by Angela Carter -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response> -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>