% 40 Ejercicios con OTTER/MACE (de TPTP) %============================================================================== %------------------------------------------------------------------------------ % Problem 1: Dreadbury Mansion % English : Someone who lives in Dreadbury Mansion killed Aunt Agatha. % Agatha, the butler, and Charles live in Dreadbury 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 Aunt % Agatha hates. No one hates everyone. Agatha is not the % butler. Therefore : Agatha killed herself. %------------------------------------------------------------------------------ % Problem 2: The Animals Puzzle % English : 1) The only animals in this house are cats. % 2) Every animal is suitable for a pet, that loves to gaze at % the moon. % 3) When I detest an animal, I avoid it. % 4) No animals are carnivorous, unless they prowl at night. % 5) No cat fails to kill mice. % 6) No animals ever take to me, except what are in this house. % 7) Kangaroos are not suitable for pets. % 8) None but carnivora kill mice. % 9) I detest animals that do not take to me. % 10) Animals that prowl at night always love to gaze at the moon. % The problem is to prove that "I always avoid a kangaroo". %------------------------------------------------------------------------------ % Problem 3: The Barber Puzzle % English : There is a barbers' club that obeys the following three % conditions: % (1) If any member A has shaved any other member B - whether % himself or another - then all members have shaved A, % though not necessarily at the same time. % (2) Four of the members are named Guido, Lorenzo, Petrucio, % and Cesare. % (3) Guido has shaved Cesare. % Prove Petrucio has shaved Lorenzo %------------------------------------------------------------------------------ % Problem 4: The Letters Puzzle % English : (1) All the dated letters in this room are written on blue paper. % (2) None of them are in black ink except those that are written % in the third person. % (3) I have not filed any of them that I can read. % (4) None of them that are written on one sheet are undated. % (5) All of them that are not crossed are in black ink. : % (6) All of them written by Brown begin with "Dear Sir" : % (7) All of them written on blue paper are filed. : % (8) None of them written on more than one sheet are crossed. % (9) None of them that begin with "Dear Sir" are written % in third person. % Prove that letters by Brown cannot be read. %------------------------------------------------------------------------------ % Problem 5: The Lion and the Unicorn % English : Lion lies on Monday, Tuesday and Wednesday. Unicorn lies % on Thursday, Friday and Saturday. Both tell truth on other % days. Both say yesterday was one of their lying days. Prove % that today is Thursday. %------------------------------------------------------------------------------ % Problem 6: Missionaries and Cannibals % English : There are 3 missionaries, 3 cannibals, and a boat on the west % bank of a river. All wish to cross, but the boat holds % at most 2 people. If the cannibals ever outnumber the % missionaries on either bank of the river the outnumbered % missionaries will be eaten. Can they all safely cross the % river? If so, how? (The boat cannot cross empty.) %------------------------------------------------------------------------------ % Problem 7: Looking for Oona % English : In another curious incident, when the husband arrived on an % island looking for Oona, he met 5 natives A,B,C,D,E who all % guessed his purpose and grinned at meeting him. They said: % A: Oona is on this island. B: Oona is not on this island. % C: Oona was here yesterday. D: Oona is not here today, and she % was not here yesterday. E: Either D is a knave or C is a knight. % The logician thought for a while, but could get nowhere. `Won't % one of you please make another statement?' the logician pleaded. % At this point A said: Either E is a knave or C is a knight. Is % Oona on the island?" %------------------------------------------------------------------------------ % Problem 8: Who owns the zebra? % English : There are five consecutive houses, each of a different color % and inhabited by men of different nationalities. They each % own a different pet, have a different favorite drink and % drive a different car. % 1. The Englishman lives in the red house. % 2. The Spaniard owns the dog. % 3. Coffee is drunk in the green house. % 4. The Ukrainian drinks tea. % 5. The green house is immediately to the right of the % ivory house. % 6. The Porsche driver owns snails. % 7. The Masserati is driven by the man who lives in the % yellow house. % 8. Milk is drunk in the middle house. % 9. The Norwegian lives in the first house on the left. % 10. The man who drives a Saab lives in the house next to % the man with the fox. % 11. The Masserati is driven by the man in the house next % to the house where the horse is kept. % 12. The Honda driver drinks orange juice. % 13. The Japanese drives a Jaguar. % 14. The Norwegian lives next to the blue house. % The problem is: Who owns the Zebra? Who drinks water? %------------------------------------------------------------------------------ % Problem 9: The Mislabeled Boxes % English : There are three boxes a, b, and c on a table. Each box contains % apples or bananas or oranges. No two boxes contain the same % thing. Each box has a label that says it contains apples or says % it contains bananas or says it contains oranges. No box contains % what it says on its label. The label on box a says "apples". % The label on box b says "oranges". The label on box c says % "bananas". You pick up box b and it contains apples. What do % the other two boxes contain? %------------------------------------------------------------------------------ % Problem 10: The School Boys : Prove some monitors are awake % English : "All the boys, in a certain school, sit together in one large % room every evening. They are of no less than five % nationalities - English, Scotch, Welsh, Irish, and German. % One of the Monitors (who is a great reader of Wilkie Collins' % novels) is very observant and takes MS. notes of almost % everything that happens, with the view of being a good % sensational witness, in case any conspiracy to commit % a murder should be afoot. The following are some of his % notes : % (1) Whenever some of the English boys are singing "Rule, % Britannia," and some not, some of the Monitors are wide awake. % (2) Whenever some of the Scotch are dancing reels, and some of % the Irish fighting, some of the Welsh are eating toasted % cheese. % (3) Whenever all the Germans are playing chess, some of the % Eleven are not oiling their bats. % (4) Whenever some of the Monitors are asleep, and some not, % some of the Irish are fighting. % (5) Whenever some of the Germans are playing chess, and none % of the Scotch are dancing reels, some of the Welsh are not % eating toasted cheese. % (6) Whenever some of the Scotch are not dancing reels, and % some of the Irish are not fighting, some of the Germans are % playing chess. % (7) Whenever some of the Monitors are awake, and some of the % Welsh are eating toasted cheese, none of the Scotch are % dancing reels. % (8) Whenever some of the Germans are not playing chess, and % some of the Welsh are not eating toasted cheese, none of the % Irish are fighting. % (9) Whenever all of the English are singing "Rule, Britannia," % and some of the Scotch are not dancing reels, none of the % Germans are playing chess. % (10) Whenever some of the English are singing "Rule, Britannia", % and some of the Monitors are asleep, some of the Irish are % not fighting. % (11) Whenever some of the Monitors are awake, and some of the % Eleven are not oiling their bats, some of the Scotch are % dancing reels. % (12) Whenever some of the English are singing "Rule, % Britannia," and some of the Scotch are not dancing reels, % Here the MS. breaks off suddenly. The problem is to complete % the sentence, if possible. %------------------------------------------------------------------------------ % Problem 11: The School Boys : Prove that all monitors are awake % English : "All the boys, in a certain school, sit together in one large % room every evening. They are of no less than five % nationalities - English, Scotch, Welsh, Irish, and German. % One of the Monitors (who is a great reader of Wilkie Collins' % novels) is very observant and takes MS. notes of almost % everything that happens, with the view of being a good % sensational witness, in case any conspiracy to commit % a murder should be afoot. The following are some of his % notes. % (1) Whenever some of the English boys are singing "Rule, % Britannia," and some not, some of the Monitors are wide awake. % (2) Whenever some of the Scotch are dancing reels, and some % of the Irish fighting, some of the Welsh are eating toasted % cheese. % (3) Whenever all the Germans are playing chess, some of the % Eleven are not oiling their bats. % (4) Whenever some of the Monitors are asleep, and some not, % some of the Irish are fighting . % (5) Whenever some of the Germans are playing chess, and none % of the Scotch are dancing reels, some of the Welsh are not % eating toasted cheese. % (6) Whenever some of the Scotch are not dancing reels, and % some of the Irish are not fighting, some of the Germans are % playing chess. % (7) Whenever some of the Monitors are awake, and some of the % Welsh are eating toasted cheese, none of the Scotch are % dancing reels. % (8) Whenever some of the Germans are not playing chess, and % some of the Welsh are not eating toasted cheese, none of the % Irish are fighting. % (9) Whenever all of the English are singing "Rule, % Britannia," and some of the Scotch are not dancing reels, % none of the Germans are playing chess. % (10) Whenever some of the English are singing "Rule, % Britannia,", and some of the Monitors are asleep, some of the % Irish are not fighting. % (11) Whenever some of the Monitors are awake, and some of the % Eleven are not oiling their bats, some of the Scotch are % dancing reels. % (12) Whenever some of the English are singing "Rule, % Britannia," and some of the Scotch are not dancing reels, % Here the MS. breaks off suddenly. The problem is to complete % the sentence, if possible. %------------------------------------------------------------------------------ % Problem 12: Checkerboard and Dominoes : Opposing corners removed % English : There is a checker board whose upper left and lower right % squares have been removed. There is a box of dominoes that % are one square by two squares in size. Can you exactly cover % the checker board with dominoes? The size is the dimension of % the checker board. %------------------------------------------------------------------------------ % Problem 13: Checkerboard and Dominoes : Row 1, columns 2 and 3 removed % English : There is a checker board whose second and third squares from % the first row have been removed. There is a box of dominoes % that are one square by two squares in size. Can you exactly % cover the checker board with dominoes? The size is the % dimension of the checker board. %------------------------------------------------------------------------------ % Problem 14: The Houses % English : There are 5 houses, 5 people, 5 colors, 5 drinks, 5 games, % and 4 pets. Each house has a person, a color, a drink, and % game, and all but one of the houses has a pet. The problem % is to match each house with as many properties as possible. % House 1 is at the left end and house 5 is at the right end. % The Englishman lives in the Red house. The white house % is left of the Green house. The Italian has a Guppy. Lemonade % is drunk in the Green house. The Swede lives in the house % where Coffee is drunk. The Toad lives in the house where % Backgammon is played. Racquetball is played in the yellow % house. Milk is drunk in the third house. The Russian lives % in the first house. The Camel lives next to the house where % Quoits is played. The Rat lives next to the house where % Racquetball is played. Solitaire is played in the house where % vodka is drunk. The American lives in the house where % Charades is played. The Russian lives next to the Blue house. %------------------------------------------------------------------------------ % Problem 15: The Interns % English : Three interns are residents of the same hospital. On only one % day of the week are all three interns on call. No intern % is on call on three consecutiveutive days. No two interns are % off on the same day more than once a week. The first intern % is off on Sunday, Tuesday, and Thursday. The second intern % is off on Thursday and Saturday. The third intern is off % on Sunday. Which day of the week are all three interns % on call? %------------------------------------------------------------------------------ % Problem 16: The Jobs Puzzles % English : There are four people: Roberta, Thelma, Steve, and Pete. Among % them they hold eight different jobs. Each holds exactly two jobs. % The jobs are: chef, guard, nurse, telephone operator, police % officer (either gender), teacher, actor, and boxer. The job of % a nurse is held by a male. The husband of the chef is the % telephone operator. Roberta is not a boxer. Pete has no % education past the ninth grade. Roberta, the chef, and the % police officer went golfing together. Question : Who holds % which job? %------------------------------------------------------------------------------ % Problem 17: How to Win a Bride % English : Suppose you are an inhabitant of the island of 'knights' and % 'knaves'. The knights always tell the truth and the knaves % always lie. You fall in love with a girl there and wish % to marry her. However, this girl has strange tastes; for some % odd reason she does not wish to marry a knight; she wants % to marry only a knave. But she wants a rich knave, not a poor % one. (We assume for convenience that everyone is classified % as either rich or poor.) Suppose, in fact, that you are % a rich knave. You are allowed to make only one statement, can % you convince her that you are a rich knave? %------------------------------------------------------------------------------ % Problem 18: Knights and Knaves #27 % English : There is an island with exactly two types of people : % truthtellers who always tell the truth and liars who always % lie. There are a group of three people, A, B, and C on the % island. A stranger passes by and asks A, "How many % truthtellers are among you ?" A answers indistinctly. So the % stranger asks B, "what did A say?". B replies "A said that % there is exactly one truthteller among us." Then C says, % "Don't believe B; he is lying!" What are B and C. Answer: % B is a liar and C is a truth-teller. %------------------------------------------------------------------------------ % Problem 19: Knights and Knaves #31 % English : There is an island with exactly two types of people - % truthtellers who always tell the truth and liars who always lie. % There are a group of three people, A, B, and C on the island. A % and B make the following statements. A: All of us are liars; % B: Exactly one of us is a truthteller. What are A, B, and C? % Answer: A is a liar, B is a truthteller, and C is a liar. %------------------------------------------------------------------------------ % Problem 20: Knights and Knaves #35 % English : There is an island with exactly two types of people - % truthtellers who always tell the truth and liars who always lie. % There are a group of three people, A, B, and C on the island. % A and B make the following statements. A: "B and C are the same % type". Someone asks "Are A and B of the same type ? " What does % C answer? Answer: "yes" %------------------------------------------------------------------------------ % Problem 21: Knights and Knaves #39 % English : There is an island with exactly three types of people - % truthtellers who always tell the truth, and liars who always % lie, and normals who sometimes tell the truth and sometimes % lie. We are given three people, A, B, C, one of whom is a % truthteller, one a liar, and one a normal (but not neccesarily % in that order). They make the following statements. A: I am % normal; B: That is true. C: I am not normal. What are A,B, % and C? Answer: A is a liar, B is a normal, and C is a truthteller. %------------------------------------------------------------------------------ % Problem 22: Knights and Knaves #42 % English : There is an island with exactly three types of people - % truthtellers who always tell the truth, and liars who always % lie, and normals who sometimes tell the truth and sometimes % lie. Liars are said to be of the lowest rank, normals are % middle rank, and truthtellers of the highest rank. Two people % A and B on the island make the following statements. A: I am % of lower rank than B. B: That's not true! What are the ranks % of A and B, and which of the two statements are true? Answer: % A is a normal and B is a normal. %------------------------------------------------------------------------------ % Problem 23: People at a party % English : We can always choose 3 persons who are either familiar with % each other or not familiar with each other, from 6 persons % who meet at a party. %------------------------------------------------------------------------------ % Problem 24: The pigs and balloons puzzle % English : 1) All, who neither dance on tight ropes nor eat penny-buns, % are old. % 2) Pigs, that are liable to giddiness, are treated with respect. % 3) A wise balloonist takes an umbrella with him. % 4) No one ought to lunch in public who looks ridiculous and eats % penny-buns. % 5) Young creatures, who go up in balloons, are liable to % giddiness. % 6) Fat creatures, who look ridiculous, may lunch in public, % provided that they do not dance on tight ropes. % 7) No wise creatures dance on tight ropes, if liable to % giddiness. % 8) A pig looks ridiculous, carrying an umbrella. % 9) All, who do not dance on tight ropes, and who are treated % with respect are fat. % Show that no wise young pigs go up in balloons. %------------------------------------------------------------------------------ % Problem 25: Schubert's Steamroller % English : Wolves, foxes, birds, caterpillars, and snails are animals, and % there are some of each of them. Also there are some grains, and % grains are plants. Every animal either likes to eat all plants % or all animals much smaller than itself that like to eat some % plants. Caterpillars and snails are much smaller than birds, % which are much smaller than foxes, which in turn are much % smaller than wolves. Wolves do not like to eat foxes or grains, % while birds like to eat caterpillars but not snails. % Caterpillars and snails like to eat some plants. Therefore % there is an animal that likes to eat a grain eating animal. %------------------------------------------------------------------------------ % Problem 26: Knights and Knaves #26 % English : On a certain island the inhabitants are partitioned into those % who always tell the truth and those who always lie. I landed on % the island and met three inhabitants A, B, and C. I asked A, % 'Are you a truthteller or a liar?' He mumbled something which I % couldn't make out. I asked B what A had said. B replied, 'A % said he was a liar'. C then volunteered, 'Don't believe B, he's % lying!' Prove C is a truthteller. %------------------------------------------------------------------------------ % Problem 27: The Winds and the Windows Puzzle % English : (1) There is always sunshine when the wind is in the East. % (2) When it is cold and foggy, my neighbor practices the flute. % (3) When my fire smokes, I set the door open. % (4) When it is cold and I feel rheumatic, I light my fire. % (5) When the wind is in the East and comes in gusts, my fire % smokes. % (6) When I keep the door open, I am free from headache. % (7) Even when the sun is shining and it is not cold, I keep my % window shut if it is foggy. % (8) When the wind does not come in gusts, and when I have a % fire and keep the door shut, I do not feel rheumatic. % (9) Sunshine always brings on fog. % (10) When my neighbor practices the flute, I shut the door, % even if I have no headache. % (11) When there is a fog and the wind is in the East, I feel % rheumatic. % Show that when the wind is in the East, I keep my windows shut. %------------------------------------------------------------------------------ % Problem 28: N queens problem % English : The problem is to place 3 queens on an 3x3 chess board, % so that no queen can attack another. %------------------------------------------------------------------------------ % Problem 29: Knights and Knaves #36 % English : On an island, there live exactly two types of people: knights % and knaves. Knights always tell the truth and knaves always % lie. I landed on the island, met two inhabitants, asked one of % them: "Is one of you a knight?" and he answered me. What can % be said about the types of the asked and the other person % depending on the answer I get? %------------------------------------------------------------------------------ % Problem 30: Knights and Knaves #36 % English : On an island, there live exactly two types of people: knights % and knaves. Knights always tell the truth and knaves always % lie. I landed on the island, met two inhabitants, asked one of % them: "Is one of you a knight?" and he answered me. What can % be said about the types of the asked and the other person % depending on the answer I get? %------------------------------------------------------------------------------ % Problem 31: TopSpin % English : TopSpin consists of a circular track with 20 pieces numbered % 1..20 placed in the track, with a turnstile in the track that % always holds four consecutive pieces. There are three legal % moves in TopSpin: slide all the pieces round the track in % either direction, or flip the turnstile. Given any initial % board with scrambled pieces on the track, the problem is to % find a sequence of moves that unscrambles the pieces. %------------------------------------------------------------------------------ % Problem 32: Quo vadis 1 % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is a simple goal for testing. %------------------------------------------------------------------------------ % Problem 33: Quo vadis 2 % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is an intermediate goal for testing. %------------------------------------------------------------------------------ % Problem 34: Quo vadis 3 % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is an intermediate goal for testing. %------------------------------------------------------------------------------ % Problem 35: Quo vadis 4 % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is the true goal from the puzzle. %------------------------------------------------------------------------------ % Problem 36: Quo vadis 5 % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is a medium goal for testing. %------------------------------------------------------------------------------ % Problem 37: Quo vadis 6 - initial to intermediate % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is the true goal from the puzzle. %------------------------------------------------------------------------------ % Problem 38: Quo vadis 6 - intermediate to final % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is the true goal from the puzzle. %------------------------------------------------------------------------------ % Problem 39: Take black and white balls from a bag % English : Start with a bag with 10 white balls and 9 black balls. % Take out two balls: if they have the same color, put a black % ball back; if they have a different color, put a white ball back. % The last ball left cannot be white. %------------------------------------------------------------------------------ % Problem 40: Quo vadis 7 - an unreachable state % English : bb is big block (square, size=4 tiles). % s1-s4 : 4 small square blocks, size=1 tile % v1-v4: 4 vertical blocks, size= 2 tiles % b1: horizontal block, size= 2 tiles % e1, e2 are the 2 blank tiles % It's a 5x4 playing field to move from the start state to % the goal state. This is a simple goal for testing. %------------------------------------------------------------------------------