Note that Prolog uses a paradigm called Negation as failure, which means that notp{\displaystyle \mathrm {not} ~p} is assumed if p{\displaystyle p} cannot be derived. This is different from true logical negation. While negation is failure has its benefits, it often confuses people starting to learn Prolog, as they expect true logical negation.