pwaring, Fun things I have (re)learnt about C recently:
int isn't guaranteed to be the same as the word size, only >= 16 bits.
getchar returns int, not a char.
Character literals are also int.
You can get the numeric value of a character literal digit c with: c - '0'. This assumes that 0-9 are sequential, which is true for any encoding you're likely to meet, and required from C89 onwards (see Baudot code for an example which does not meet this criterion).