Block B

Last Time We studied representations of numbers and base numbering systems. We focused on three imporatant bases in the computing world, 2, 8, and 16.

Base numbering systems have an alpahet.

We learned about money and the "greedy algorithm", which says, "Use the largest possible bill and use as many as you can. Keep doing this down through the denominations.

In base b, the "bills" are

1, b, b2, b3, ......

Here we convert 67 to binary from decimal.

denomination number of "bills" what's left
64 1 3
32 0 3
16 0 3
8 0 3
4 0 3
2 1 1
1 1 0

67 = 0b1000011

We also called this the bigendian algorithm, since it starts at the big end first.

We then considered the littleendian algorithm, which starts at the little end. It is based on these two principles. If b is a base: