The stupid question is the question not asked | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Testing it would have found
Name "main::n" used only once: possible typo at - line 5. But besides that, ** is a more expensive operation than you need here especially doing it 3 times per iteration. using 1<<$iin place of 2**$i would be a bit faster. is even better. And (push @num, (($num & 1) ? 1 : 0)) and $num>>=1 until 1 > $num;still faster... In reply to Re: Re(golf): I'm looking for the faster way to convert char 2 Bin and Bin 2 char (8bits)
by I0
|
|