% % Dreadsbury Mansion Murder Mystery % % Someone who lives in Dreadsbury Mansion killed Aunt Agatha. % % Agatha, the butler, and Charles live in Dreadsbury Mansion, and are % the only people who live therein. % % A killer always hates his victim, and is never richer than his victim. % Charles hates no one that Aunt Agatha hates. % Agatha hates everyone except the butler. % The butler hates everyone not richer than Aunt Agatha. % The butler hates everyone Agatha hates. % No one hates everyone. % Agatha is not the butler. % set(auto). formula_list(usable). % Someone who lives in Dreadsbury Mansion killed Aunt Agatha. exists x (lives(x) & killed(x, agatha)). % Agatha, the butler, and Charles live in Dreadsbury Mansion, and are % the only people who live therein. lives(agatha) & lives(butler) & lives(charles). all x (lives(x) -> (x = agatha | x = butler | x = charles)). % A killer always hates his victim, and is never richer than his victim. all x all y (killed(x,y) -> hates(x,y)). all x all y (killed(x,y) -> -richer(x,y)). % Charles hates no one that Aunt Agatha hates. all x (hates(agatha,x) -> -hates(charles,x)). % Agatha hates everyone except the butler. all x (-(x = butler) -> hates(agatha,x)). % The butler hates everyone not richer than Aunt Agatha. all x (-richer(x,agatha) -> hates(butler,x)). % The butler hates everyone Agatha hates. all x (hates(agatha, x) -> hates(butler,x)). % No one hates everyone. all x exists y (-hates(x,y)). %Agatha is not the butler -(agatha = butler). %Agatha killed herself -killed(agatha,agatha). end_of_list.