Converts between numbers of different bases.