On Mon, Jan 9, 2023, 5:56 PM Alex ... <[email protected]> wrote:

> Maybe this is cheating but MFORTH gives me this one liner arbitrary base
> converter. 😁
>
> : BC BASE @ >R BASE ! . R> BASE ! ;
>
> Examples:
> 255 16 BC FF
> 23 2 BC 10111
> HEX D2 DECIMAL 8 BC 322
>

Yeah Forth takes the cake on interactive stuff like this.

-- John.

Reply via email to