And a non-recursive one:sub c { my$a=pop;$a==1?1:8**($a-1)+c($a-1) }
updates on that last bit of codesub c { my$a=1;$a+=8**$_ for(1..pop-1);$a }
In reply to Re: Intriguing problem; maybe golf?
by Masem
in thread Intriguing problem; maybe golf?
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |