Theory and practice of logic programming (University Press, 2001)