Text this: Logic, programming and Prolog