in reply to Deleting trailing 0's after using sprintf

Minor nitpick: $percent_change =~ s/0+$// if $percent_change =~ /0+$/; the modifying if statement is redundant, the s/// operator only replaces if it matches in the first place.

Replies are listed 'Best First'.
Re: Re: Deleting trailing 0's after using sprintf
by Popcorn Dave (Abbot) on Mar 20, 2004 at 03:16 UTC
    Very good point. My logic was correct, but I did have one to many tests. Thanks for pointing that out!

    There is no emoticon for what I'm feeling now.