more useful options | |
PerlMonks |
Re: Concatenate and joinby Cristoforo (Curate) |
on Mar 31, 2016 at 03:54 UTC ( [id://1159179]=note: print w/replies, xml ) | Need Help?? |
Another way using the transliteration operator. Assumes a 12 digit address.
Update: Changed the transliteration to bind with the regex match. The former line was: my $mac_R5 = join ".", $addr =~ tr/://d && $addr =~ /..../g; Which works for perls before version 5.014.
In Section
Seekers of Perl Wisdom
|
|