# 342 logic/ropes.p

Two fifty foot ropes are suspended from a forty foot ceiling, about
twenty feet apart. Armed with only a knife, how much of the rope can
you steal?

logic/ropes.s

Almost all of it. Tie the ropes together. Climb up one of them. Tie
a loop in it as close as possible to the ceiling. Cut it below the
loop. Run the rope through the loop and tie it to your waist. Climb
the other rope (this may involve some swinging action). Pull the rope
going through the loop tight and cut the other rope as close as
possible to the ceiling. You will swing down on the rope through the
loop. Lower yourself to the ground by letting out rope. Pull the
rope through the loop. You will have nearly all the rope.

logic/same.street.p

Sally and Sue have a strong desire to date Sam. They all live on the
same street yet neither Sally or Sue know where Sam lives. The houses
on this street are numbered 1 to 99.

Sally thinks she now knows the address of Sam's house and decides to
visit.

When she gets there, she finds out she is wrong. This is not
surprising, considering Sam answered only the second question
truthfully.

Sue, unaware of Sally's conversation, asks Sam two questions.

Sue thinks she knows where Sam lives and decides to pay him a visit.
She too is mistaken as Sam once again answered only the second
question truthfully.

If I tell you that Sam's number is less than Sue's or Sally's,
and that the sum of their numbers is a perfect square multiplied
by two, you should be able to figure out where all three of them
live.

logic/same.street.s

Sally thinks she now knows the address of Sam's house and decides to
visit.

Since Sally thinks that she has enough information, I deduce
that Sam answered that his house number was a perfect square
greater than 50. There are two of these {64,81} and Sally must
live in one of them in order to have decided she knew where Sam
lives.

When she gets there, she finds out she is wrong. This is not
surprising, considering Sam answered only the second question
truthfully.

So Sam's house number is greater than 50, but not a perfect
square.

Sue, unaware of Sally's conversation, asks Sam two questions.

Observation: perfect cubes greater than 25 are {27, 64}, less
than 25 are {1,8}.

Sue thinks she knows where Sam lives and decides to pay him a visit.
She too is mistaken as Sam once again answered only the second
question truthfully.

Since Sam's house number is greater than 50, he told Sue that
it was greater than 25 as well. Since Sue thought she knew
which house was his, she must live in either of {27,64}.

If I tell you that Sam's number is less than Sue's or Sally's,

Since Sam's number is greater than 50, and Sue's is even
bigger, she must live in 64. Assuming Sue and Sally are not
roommates (although awkward social situations of this kind are
not without precedent), Sally lives in 81.

and that the sum of their numbers is a perfect square multiplied
by two, you should be able to figure out where all three of them
live.

```	Sue + Sally + Sam = 2 p^2        for p an integer
64  + 81    + Sam = 2 p^2
```

Applying the constraint 50 < Sam < 64, looks like Sam = 55 (p = 10).

In summary,
Sam = 55
Sue = 64
Sally = 81

-- Tom Smith <tom@ulysses.att.com>

Continue to: