Allen asks:
> Now how do I do
> this in reverse? If I know the sum is 81, how do I determine that the
> numbers that make up this sum are 1 + 16 + 64?
Simply begin with the largest power of two smaller than 81 (in this case, 64)
and subtract it out. Then repeat the process, subtracting the largest power
of two from whatever remains. And then repeat again, until nothing is left.
This general process works for converting any number base to any number base.
Wirt Atmar