Category Archives: factor

Roman Numeral Fun

In my waiting-for-people-to-leave-so-I-can-get-into-classrooms time at work I wrote a roman numeral translator in Factor. It’s a bit different from your normal implementation as Factor’s parser actually does almost all the work: USING: strings parser kernel words sequences math ; : NUMERAL: CREATE dup reset-generic dup t “parsing” set-word-prop parse-definition \ parsed add define-compound ; parsing [...]

Checklist

The code for generating the checklist is written in Factor. Factor is rather outside the mainstream, but it works beautifully for my purposes. I store the checklist data in a text file that looks like the following: CHECKLIST: FAMILY: Wrens SPECIES: Carolina Wren STATUS: Fairly common year-round. Can be found almost anywhere. There’s too many [...]