Adam D. Ruppe:
write(" %d: %d\n", bd, an);This should be writef instead of write. writef uses the format string, plain write just literally outputs its arguments.
A statically typed language should give a compile-time error for such mistake. It's a leftover from the weakly typed C mindset. In many cases format strings are known at compile-time.
Bye, bearophile
