Some programs I wrote while learning Prolog