lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


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?