umm.. there's several ways.
The following assumes you chomped the line already. see perldoc -f chomp

if length($line)
if $line # assuming it won't just have a 0 in it.
if $line !~ /^$/



> -----Original Message-----
> From: lz [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, May 28, 2002 10:09 AM
> To: [EMAIL PROTECTED]
> Subject: checking for an empty string
> 
> 
> Hi guys,
> 
> while($line = <STDIN>)
> {
>     if ($line =~ /^email address/)
>     {
>      }
> }
> 
> How can I check if $line contains a value or is empty?
> 
> Thanks a lot!
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! - Official partner of 2002 FIFA World Cup
> http://fifaworldcup.yahoo.com
> 
> -- 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

----------------------------------------------------------------------------
--------------------
The views and opinions expressed in this email message are the sender's
own, and do not necessarily represent the views and opinions of Summit
Systems Inc.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to