my @digits; while ($num > 0) { unshift @digits, $num % 20; $num = int($num / 20); } @digits = 0 if !@digits;
Or you can use an existing module, like Convert::BaseN. (I have no experience with it; I just picked one pretty arbitrarily.)
In reply to Re: Base20 Blues
by ikegami
in thread Base20 Blues
by JimDuyer
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |