[net.puzzle] Boodle Phil moiven?

cipher@mmm.UUCP (Andre Guirard) (12/02/85)

Distribution:


[ Replace this line with your favorite fictional foreign language. ]

There is no gold hidden in this puzzle.

Lucy sod'n pho Abner, kips Abner sod'n pho Lucy.  Hubert bink ptui
Phil, kips Hubert bink ptui Abner.  Leonard sod'n pho Phil.  Lucy pock
matoo Leonard myt Leonard pock matoo Myrtle, kips Myrtle moiven Lucy.
Lucy sod'n pho Hubert myt Myrtle sod'n pho Hubert, kips Lucy pock matoo
Myrtle.  Leonard moiven Hubert myt Hubert bink ptui Phil, kips Leonard
moiven Phil.

Kips, boodle Phil moiven?

Respond via e-mail.  Answer will be posted in about a month.
-- 

 /''`\						Andre Guirard
([]-[])						De Tuss from de Tonn
 \ o /						ihnp4!mmm!cipher
  `-'

goldsten@uiucdcsb.CS.UIUC.EDU (12/09/85)

/* Written  8:41 am  Dec  2, 1985 by cipher@mmm.UUCP in uiucdcsb:net.puzzle */
/* ---------- "Boodle Phil moiven?" ---------- */
Distribution:


[ Replace this line with your favorite fictional foreign language. ]

There is no gold hidden in this puzzle.

Lucy sod'n pho Abner, kips Abner sod'n pho Lucy.  Hubert bink ptui
Phil, kips Hubert bink ptui Abner.  Leonard sod'n pho Phil.  Lucy pock
matoo Leonard myt Leonard pock matoo Myrtle, kips Myrtle moiven Lucy.
Lucy sod'n pho Hubert myt Myrtle sod'n pho Hubert, kips Lucy pock matoo
Myrtle.  Leonard moiven Hubert myt Hubert bink ptui Phil, kips Leonard
moiven Phil.

Kips, boodle Phil moiven?

Respond via e-mail.  Answer will be posted in about a month.
-- 

 /''`\						Andre Guirard
([]-[])						De Tuss from de Tonn
 \ o /						ihnp4!mmm!cipher
  `-'
/* End of text from uiucdcsb:net.puzzle */

ags@pucc-h (Dave Seaman) (12/11/85)

This appears to be a programming exercise in Prolog.

> Lucy sod'n pho Abner, kips Abner sod'n pho Lucy.

person(lucy).
person(abner).
sodn_pho(X,Y) :- simple_sodn_pho(X,Y).
sodn_pho(X,Y) :- simple_sodn_pho(Y,X).
simple_sodn_pho(lucy,abner).

> Hubert bink ptui Phil, kips Hubert bink ptui Abner.

person(hubert).
person(phil).
bink_ptui(X,Y) :- person(X), person(Y), test_bink_ptui(X,Y).
test_bink_ptui(hubert,phil) :- !.
test_bink_ptui(X,Y) :- nonvar(Y), test_bink_ptui(X,_), !.

> Leonard sod'n pho Phil.

person(leonard).
simple_sodn_pho(leonard,phil).

> Lucy pock matoo Leonard myt Leonard pock matoo Myrtle, kips Myrtle moiven 
> Lucy.  Lucy sod'n pho Hubert myt Myrtle sod'n pho Hubert, kips Lucy pock 
> matoo Myrtle.  Leonard moiven Hubert myt Hubert bink ptui Phil, kips 
> Leonard moiven Phil.

person(myrtle).
simple_sodn_pho(lucy,hubert).
simple_sodn_pho(myrtle,hubert).

pock_matoo(X,Y) :- person(X), person(Y), test_pock_matoo(X,Y).
test_pock_matoo(lucy,leonard) :- !.
test_pock_matoo(leonard,myrtle) :- !.
test_pock_matoo(X,Y) :- sodn_pho(X,Z), sodn_pho(Y,Z), !.

moiven(X,Y) :- person(X), person(Y), test_moiven(X,Y,[Y]).
test_moiven(leonard,hubert,_) :- !.
test_moiven(X,Y,_) :- pock_matoo(Y,Z), pock_matoo(Z,X), !.
test_moiven(X,Y,P) :- bink_ptui(Z,Y),
		      not(member(Z,P)),
		      test_moiven(X,Z,[Z|P]),
		      !.

member(X,[X|_]).
member(X,[_|Y]) :- member(X,Y).

> Kips, boodle Phil moiven?

?- moiven(phil,X).

X = phil ;

no

--------------------------------------------------------------------------

Kips, Phil moiven nar Phil.  [The answer.]

	"When I use a word," Humpty Dumpty said, in a rather scornful
	tone, "it means just what I choose it to mean -- neither more
	nor less."

The database, in somewhat cleaner form:
--------------------------------------------------------------------------

person(lucy).
person(abner).
person(hubert).
person(phil).
person(leonard).
person(myrtle).

sodn_pho(X,Y) :- simple_sodn_pho(X,Y).
sodn_pho(X,Y) :- simple_sodn_pho(Y,X).

simple_sodn_pho(lucy,abner).
simple_sodn_pho(leonard,phil).
simple_sodn_pho(lucy,hubert).
simple_sodn_pho(myrtle,hubert).

bink_ptui(X,Y) :- person(X), person(Y), test_bink_ptui(X,Y).
test_bink_ptui(hubert,phil) :- !.
test_bink_ptui(X,Y) :- nonvar(Y), test_bink_ptui(X,_), !.

pock_matoo(X,Y) :- person(X), person(Y), test_pock_matoo(X,Y).
test_pock_matoo(lucy,leonard) :- !.
test_pock_matoo(leonard,myrtle) :- !.
test_pock_matoo(X,Y) :- sodn_pho(X,Z), sodn_pho(Y,Z), !.

moiven(X,Y) :- person(X), person(Y), test_moiven(X,Y,[Y]).
test_moiven(leonard,hubert,_) :- !.
test_moiven(X,Y,_) :- pock_matoo(Y,Z), pock_matoo(Z,X), !.
test_moiven(X,Y,P) :- bink_ptui(Z,Y),
		      not(member(Z,P)),
		      test_moiven(X,Z,[Z|P]),
		      !.

member(X,[X|_]).
member(X,[_|Y]) :- member(X,Y).
-- 
Dave Seaman	  					pur-ee!pucc-h!ags

cipher@mmm.UUCP (Andre Guirard) (01/22/86)

Previously I posted a puzzle in a strange foreign language describing
the relationships among various persons.  That puzzle is reproduced
below, and the solution given.

I received one incorrect solution via e-mail from Mark Brader
(dciem!msb).  He mistakenly assumes that "pock matoo" is reflexive (in
all fairness, I must admit that he points out that this does not follow
logically, but when you work a logic puzzle, you must assume only what
follows logically or what you know to be true from real-world
experience).  Dave Seaman's posted answer is correct, but it does not
give the reasoning used to arrive at the answer.  Also, it is a little
obscure to those not familiar with Prolog.

The puzzle:

Lucy sod'n pho Abner, kips Abner sod'n pho Lucy.  Hubert bink ptui
Phil, kips Hubert bink ptui Abner.  Leonard sod'n pho Phil.  Lucy pock
matoo Leonard myt Leonard pock matoo Myrtle, kips Myrtle moiven Lucy.
Lucy sod'n pho Hubert myt Myrtle sod'n pho Hubert, kips Lucy pock matoo
Myrtle.  Leonard moiven Hubert myt Hubert Bink ptui Phil, kips Leonard
moiven Phil.
Kips, boodle Phil moiven?

Answer: substitute "whom" for "boodle", "therefore" for "kips", and
"and" for "myt" (the meaning of the note, "there is no gold hidden in
this puzzle" in the original posting was that the word "or" was not
used).  The statements then assume the form of logical expressions.

	(1)  A sp B implies B sp A.
	(2)  A bp B implies A bp C
	(3)  A pm B and B pm C implies C m A
	(4)  A sp B and C sp B implies A pm C
	(5)  A m B and B bp C implies A m C

The line of reasoning which leads to the correct answer, "Phil moiven
Phil," is as follows:

Phil sod'n pho Leonard myt Phil sod'n pho Leonard, kips Phil pock matoo
Phil (4).  Phil pock matoo Phil myt Phil pock matoo Phil, kips Phil
moiven Phil (3).

I will not attempt to demonstrate here that Phil cannot be shown to
moiven any of the others.  You're welcome to try it yourself if you
like.  

Incidentally, Seaman's posted answer, "Phil moiven nar Phil," is of
course semantically incorrect.  He could have said, "Phil moiven
_sar_," the word "sar" indicating that the object of the sentence is
identical to the subject, or "Phil moiven Phil," but the word "nar"
indicates that the object of the sentence is a watermelon, which of
course cannot be deduced logically from the information given.

If some other people posted correct answers which I missed, sorry about
that!  We've been having problems with our news feed recently here in
MN, and I'm sure I missed all kinds of interesting stuff.
-- 

(___)						Andre Guirard
|_ _|						The Devil Himself
( v )						ihnp4!mmm!cipher
 \-/
  V

ags@pucc-h (Dave Seaman) (01/23/86)

In article <418@mmm.UUCP> cipher@mmm.UUCP (Andre Guirard) writes:
>Incidentally, Seaman's posted answer, "Phil moiven nar Phil," is of
>course semantically incorrect.  He could have said, "Phil moiven
>_sar_," the word "sar" indicating that the object of the sentence is
>identical to the subject, or "Phil moiven Phil," but the word "nar"
>indicates that the object of the sentence is a watermelon, which of
>course cannot be deduced logically from the information given.

Andre seems to have forgotten the other meaning of "nar," which is
"only."  Neither of his suggested answers, "Phil moiven sar" or
"Phil moiven Phil" conveys the meaning that Phil moiven no one else
but Phil, which was established by the fact that the prolog program
turned up no alternate solutions.
-- 
Dave Seaman	  					pur-ee!pucc-h!ags