[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: tostring(e,[base])
- From: Petite Abeille <petite.abeille@...>
- Date: Tue, 26 Jul 2011 22:17:28 +0200
On Jul 26, 2011, at 6:23 PM, Stuart P. Bentley wrote:
> Actually, you can accept bases lower than 2: you just have to treat them as special cases.
>
> I wrote a similar function a while back (oriented toward arbitrary digit systems, such as a base 32 that doesn't use I or O), except that it doesn't use reverse() after concatenating, so you can use digits of any length:
> https://gist.github.com/807158
Nice. But then you must have a function to reverse your handy work, similar to Lua's own tonumber (e [, base]), no?