Added support for numbers of other bases e.g.2,8,16,36