P is for Practical | |
PerlMonks |
Re: Colorizeby marcink (Monk) |
on Jun 12, 2001 at 18:06 UTC ( [id://87804]=note: print w/replies, xml ) | Need Help?? |
1. you can use my $phrase=shift; instead of my $phrase = shift(@_); -- @_ is the default parameter in list context. 2. in scalar context @colors == $#colors + 1 3. the HTML you create contains one FONT tag per letter, but you don't need more than @colors of them. You could change the loop to get one pass per color instead of one pass per character. -mk
In Section
Cool Uses for Perl
|
|