I have an 11 digit number. I want to add another number to it and format to 11 digits as well.
my $amount1 = 14313562897; my $amount2 = 00000013625; $amount = sprintf("%011d", $amount1 + $amount2); print $amount."\n"; The answer perl gives me is -0000000001 How can this be ? As well, if the large number starts with 0, I get an "Illegal octal digit '8' at test.pl line 2, at end of line". As though perl cant handle numbers bigger than 10 digits or so. ???? *********************************************************************************** This e-mail, including any attachments to it, may contain confidential and/or personal information. If you have received this e-mail in error, you must not copy, distribute, or disclose it, use or take any action based on the information contained within it. Please notify the sender immediately by return e-mail of the error and then delete the original e-mail. The information contained within this e-mail may be solely the opinion of the sender and may not necessarily reflect the position, beliefs or opinions of Salmat on any issue. This email has been swept for the presence of computer viruses known to Salmat's anti-virus systems. For more information, visit our website at www.salmat.com.au. ***********************************************************************************
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>