Yes

($org) = ($1 =~ s/,//g);

Is the same as
$1 =~ s/,//g;
$org = $1;

-----Original Message-----
From: Paul Kraus [mailto:[EMAIL PROTECTED]] 
Sent: Friday, December 27, 2002 2:21 PM
To: 'Paul Kraus'; 'Perl'
Subject: RE: Why do these two statements generate different output?


ok I was wrong. Its Friday so I am half alert :) the 17094. is actually the
tail end of this error.

Modification of a read-only value attempted at armonth.pl line 30, <AGING>
line 17904.

Are you able to make an assignment like this?

> -----Original Message-----
> From: Paul Kraus [mailto:[EMAIL PROTECTED]]
> Sent: Friday, December 27, 2002 3:19 PM
> To: Perl
> Subject: Why do these two statements generate different output?
> 
> 
> $1 from reg expr is equal to 2300,150.17
> 
> $org = $1;
> $org=~s/,//g;
> Generates 2300150.17. Which is correct.
> 
> $org = $1 =~ s/,//g;
> Generates 17904.
> 
> Now if I am correct the binding =~ has precedence over =. So
> it should generate the same output.
> 
> Paul Kraus
> Network Administrator
> PEL Supply Company
> 216.267.5775 Voice
> 216-267-6176 Fax
> www.pelsupply.com
> 
> 


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

Reply via email to