Convert to and from any base