note
merlyn
[davorg] says:
<blockquote>
It's still two lines, but the first is just there so I don't have to type '%02x' six times :)
</blockquote>
Well then, don't!
<code>
$mac = sprintf "%02x" x 6, map hex, split /\./, $mac;
</code>
There. One line. :)
<p>-- <a href="http://www.stonehenge.com/merlyn/">Randal L. Schwartz, Perl hacker</a></p>
26155
26156