Go buy, beg, borrow or steal ;-)  'Learning Perl'.  It is the *best*
introductory programming book yet written.  Not that I am biased or
anything...


"James Parsons" <[EMAIL PROTECTED]> wrote in message
725FADC37060D6118A02000255477DC00152FE8F@ETR_NT4">news:725FADC37060D6118A02000255477DC00152FE8F@ETR_NT4...
> Ok here  go's ,  I'm just starting to Learn Perl  and it's a very slow
> process.
>
> I have this script the calculates the sum  a bunch of  numbers and prints
> the final number to file, but my problem is I would like the number to
have
> a floating  $sign but I'm sure how do this
>
> Any help would  be great
>
>
> Script:
>
> #!/usr/bin/perl -w
>
> use strict;
>
> my $total = 0;
>
> open(FILE,"/usr/local/logs/pos/dollar_me") || die $!;
>
> $total += $_ while(<FILE>);
>
> close(FILE);
>
> printf ("%7.2f\n",$total);
>
>
> The number comes out as 120.23   instead of $120.23..
>
>
> Thanks
> James Parsons.
>



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

Reply via email to