E-Code

Number base converter (2 to 36) — a TI-89 Titanium program

By E-Code · updated

BASE89 is a TI-89 BASIC program for the TI-89 Titanium. Convert a whole number written in any base from 2 to 36 (digits 0-9 then A-Z) to any other base, with its decimal value — exact at any size, because the TI-89 keeps whole numbers exact.

What it asks for and what it shows

It asks for 3 values at its prompts. In the example below it shows DECIMAL, IN BASE 16:, FF, DIGITS.

Example run

One of its oracle test cases: “255 to hex”. The inputs are typed in order, and the results are the values the case expects on the screen.

StepValue
You enter
Input 1255
Input 210
Input 316
The screen shows
DECIMAL=255
TextIN BASE 16:
TextFF
DIGITS=2

How it's checked

5 test cases, each checked against an independent method. Replayed key by key on a virtual TI-89 Titanium, they make 28 checks.

How E-Code checks every program

Run it or put it on your calculator

Related programs

All TI-89 Titanium programs