Solves HORNSAT