WUV

TorgoX on 2006-02-07T02:26:13

Dear Log,

Tie::Comma, I wuv yoooo!

I know it's just a special case of MJD's good old Interpolation module, but it's still WUVVABLE.

(Altho ideally I'd just be able to use a (s)printf format to get commafication, but apparently there's nobody with the right derring-do to make that happen.)


Tie::Formatted

pemungkah on 2006-02-07T20:17:31

use Tie::Formatted;
printf "This is hex: $format{12, 18, 35, 42, '%02x'}\n";
prints
This is hex: 0c 12 23 2a
Plus if you prefer a different name for the magic hash:
use Tie::Formatted qw(f);
print "$f{142857, '%08x'}\n";
gives
00022e09
There. :)