• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Paradoxes and Ironies!!!!

 
Ranch Hand
Posts: 187
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Few centuries ago, a Law teacher came across a student who was willing to learn but was unable to pay the fee. The student struck a deal saying, "I would pay your fee the day I win my first case in the court". Teacher agreed and proceeded with the law course. When the course was finished and teacher started pestering the student to pay up the fee, student reminded the deal and pushed days.
Fed up with this, the teacher decided to sue the student in the court of law and both of them decided to argue for themselves.
The teacher put forward his argument saying: "If I win this
case, as per the court of law, student has to pay me. And if I lose the case, student will still pay me because he would have won his first case. So either way i will have to get the money".
Equally brilliant student argued back saying: "If I win the case, as per the court of law, I don't have to pay anything to the teacher. And if I lose the case, I don't have to pay him because I haven't won my first case yet. So either way, I am
not going to pay the teacher anything".
This is one of the greatest paradoxes ever recorded in history.
eagerbeaver.
 
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

But I remember reading about it in slightly different context: it was asked what you would decide if you were a judge?
Also, there is a way for the teacher to win...
 
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yeah, the teacher evidently wasn't very smart in the way he went about this. It's his own fault if he doesn't get the money.
 
Eager Beaver
Ranch Hand
Posts: 187
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey guys,
We are not sitting on judgement here.....please come forward with any factual paradox or Irony that makes for interesting reading.
thanks,
eagerbeaver.
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, to spoil mystery a little:
When a judge is making decision, the student has not won won his (or her ?) first case yet. So the student wins. But then the teacher sues him (or still her?) again, and this time a judge can do nothing but to give a victory to the teacher
Conclusion: complicated tasks should be divided in steps and hadled consecutively
Conclusion2: �any problem in computing can be solved by adding another level of indirection� http://www.xml.com/pub/a/2000/11/29/deviant.html
In our case, the first trial was a pre-processor for the second

[This message has been edited by Mapraputa Is (edited April 27, 2001).]
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Eager, (or Beaver??? ), it was a great idea, to start this topic! Can we post puzzles also?
Here is my favourite: there are three numbers: 0, 1, 2 and two players. Player1 choose one number, player2 can ask one question and player1 can answer only �yes�, �no�, or �I do not know�. Player2 mission is, naturally, guess the number.
(I observed that often people waste time playing mathematical tricks with 0, 1, 2 � no need, the solution is purely logical. Actually, any three increasing numbers will fit: 2, 10, 133 construct the same problem).
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm not sure I follow your logic, Map. After the first suit, the result is ambiguous - how can you say the student wins? And how does the second lawsuit change this?
My own idea here was that the teacher should have sued the student over some other issue. It could be anything, some made-up issue that couldn't possibly stand up in court; that's fine. As long as he sues for a huge amount of money, much greater than what the student owes. Then the most likely outcome is that the student will defeat the bogus lawsuit, thereby winning his case and requiring him to pay the teacher. In the unlikely event that the student loses, then he must pay an even greater amount to the teacher. If the teacher wants to be fair about it, he could then return the excess money, minus court costs of course.
For Map's puzzle - "If we call your number x, then is 1/(x-1) greater than zero?" More generally, let a be the middle number of the three choices - is 1/(x-a) > 0? From the answer, it is possible to figure out what x was.
[This message has been edited by Jim Yingst (edited April 27, 2001).]
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey, Jim, not fair, you were too fast! Map spent the whole day figuring it out...
Eventhough your solution works , I still like mine better Of course, you figured out that that problems is with the answer �I do not know�. How the heck can player1 say �I do not know�, if all the informaion is open to him (or her? ) You used the fact, that division by zero gives unpredictable result, how about more generic solution? To get rid of arithmetic tricks, let�s formulate it differently:
there are three stones, each next bigger than the previous. Player1 chooses one... and so on.
Now it�s too simple, oh well...
Now about lawsuits,
I'm not sure I follow your logic, Map.
For one thing it was not Map�s logic
After the first suit, the result is ambiguous - how can you say the student wins?
When a judge makes decision, the student has not won any cases yet. So the judge has to rejects theacher�s claims.
And how does the second lawsuit change this?
It is the first, not the second lawsuit what change this. After the student won his first case, teacher�s claims are valid and the teacher wins the second lawsuit.
There are two points in this paradox: first, what makes it paradoxical, second (more practical): how can the teacher win?
Interesting, that Jim was apparently attracted by the second problem, whereas Map meditated on purely theoretical first part.
So what is the nature of this paradox? It is a logical function whose definition includes the very function.
Whether student won his first case depends on whether he won his first case!
Next point, there is an ambiguity in term �to win the case� � to win the case being a lawer is not the same, as to win being a defendant. The teacher can win only by mixing this two concepts. If the deal was formulated better than the student could win by hiring another lawer. Of course, Jim would point out that now the whole matter is how expensive is another layer comparing to tuition...
[This message has been edited by Mapraputa Is (edited April 27, 2001).]
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What is that after Johnson Chong left us, there are only three deep thinkers on the Ranch - Eager Beaver, Jim and Map. Other folk quote really deep thinkers or indulge themselves in Word Associations
 
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The Master is around. He is keeping a low profile becuase, Angela [following the footsteps of PolPot] is hunting down all intellectuals.
This is a question he sent me through the telepathic link (he has a telepathic link with every disciple who has crossed the fifth dan level).
" There is a barber who shaves every one in town who doesnt shave themsleves. May I know if the barber can shave himself or not ? "
He/she who can solve this problem is a true deep thinker.

Cheers
Sahir

[This message has been edited by Sahir Shibley (edited April 30, 2001).]
 
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Sahir Shibley:
" There is a barber who shaves every one in town who doesnt shave themsleves. May I know if the barber can shave himself or not ? "


He can if he's from out of town.

 
David Junta
Ranch Hand
Posts: 86
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Sahir Shibley:
" There is a barber who shaves every one in town who doesnt shave themsleves. May I know if the barber can shave himself or not? "


The statement only guarantees that there is nobody in town going unshaven. It does not say that if they shave themselves then the barber does NOT shave them...so they could be shaving themselves AND getting shaven by the barber, which is what would occur if the barber shaved himself. So the answer is YES, the barber can shave himself.
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear Sahir,
Thanks so much for your information.
The Master is with us, that's a good news, that's reassuring. And now it's clear why such a horrible intellectual community as a JR doesn't participate in paradox resolving actively - they are afraid of Angela's persecution. Not to say that it is Angela's personality that exhibits such obscurantist tendencies, just her official post as a moderator of Meaningless Drivel forum requires her to maintain certain level of meaninglessness and persecute too deep thinking. Oh well...
So you think that WA-1 and WA-2 are conspiratorial places where the Master talks to his flock? Oh, I mean folk tries to talk to the Master telepathically? And each word can be expanded into an excessively deep philosophical question? Could be.
"Ray Marsh: When?
Andy Ceponis: where
Jane Griscti, Sun Certified Programmer for the Java 2 Platform: how
Ling Wu: why ..."

[This message has been edited by Mapraputa Is (edited April 28, 2001).]
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
" There is a barber who shaves every one in town who doesnt shave themsleves. May I know if the barber can shave himself or not? "
Variant 1. The barber can shave himself, but he is not allowed to
Variant 2. The barber can shave himself, but he doesn���t need to, because the barber is a female.
Variant 3. The barber can shave himself, but only once ��� after it ���who doesnt shave themsleves��� N/A for him
If to be serious, ir is a famous Russell���s paradoxwhich made him to create his theory of types.
���The paradox arose in connection with the set of all sets which are not members of themselves. Such a set, if it exists, will be a member of itself if and only if it is not a member of itself.���
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Player 2 says "I've chosen one of the three numbers, but not the largest one. Is the number you've chosen larger than the one I've chosen?" If player 1 says "yes", he's chosen the largest one. If he says "no", he's chosen the smallest, and if he says "I don't know" then he's chosen the middle one.
> The barber can shave himself, but he doesn���t need to, because
> the barber is a female.
I suppose it depends on local fashion, but it seems to me that a female "needs" to shave just as much as a male. Just not in the same places. You could just as well say that the barber doesn't need to shave because he wants to grow a beard.
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Oh, thank you for asking!
This my favourite puzzle. Actually, even after I formulated it in more general sense, Jim was able to reduce it to math trick - that's amazing how creative our sheriffs are! Anyway, Jim's wit promted me to formulate it as general as possible:
there are three stones, each next bigger than the previous. Player1 chooses one, player2 can ask one question and player1 can answer only "yes", "no", or "I do not know".
Solution: the question shuld sound somewhat like "Is your stone bigger than ANY of other two"?
Pure logic.
Interesting, that everybody try to construct a resolving function from mathematical functions, it needs a mental shift to use a logical function. After I made my own shift I wondered why it took me so long if a solution is so obvious? This puzzle makes clear how narrow tunnelled our brain is. Well, at least, Map's brain.
[This message has been edited by Mapraputa Is (edited April 30, 2001).]
 
Ranch Hand
Posts: 400
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

A man wanted to pilot a helicopter, so he went to take some lessons. When he was in the helicopter, his teacher started giving him instructions over the radio. "OK, take her up to 100 metres.", the man radioed back "I'm at 100m", then the teacher said, "OK, now go to 200 metres", "I'm at 200 metres," the man reported back, "but hey...something wrong in here, I'm very cold...says the man". Suddenly the helicopter fell out of the sky and crashed to the ground...boom !


what happened ?
stevie
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ha!
When I typed my answer Jim already posted his - basically the same
Jim, I was kidding about female barber. According to Russell, no set can be a member of itself. The barber simply doesn���t exist.
There are few more paradoxes:
1. This sentence is not about itself but about whether it is about itself
2. To be successful, you should follow two rules:
1) never tell all you know
3. Were it profitable - everybody would be unselfish.
4. Hey, The Sentence, am I writing or reading you?
[This message has been edited by Mapraputa Is (edited April 30, 2001).]
 
Sahir Shibley
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

That was a good one. Very similar to creating user defined fuzzy boolean values true = 1.0 , false = 0.0 , dont know = 0.5 . By the way, are you using Greek characters in your posts, or is my browser acting up ?
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Greek characters? Looks Ok for me... But I have Cyrillic font support on my computer, so I cannot see some Spanish letters, for example. Internationalization, what did you expect... I tried to edit two my previous messages, is it better now?
Stevie, is your puzzle yes/no game? There is a whole class of them: we can ask questions and you answer only "yes" or "no". For example: Map asks: is the helicopter that fell out of the sky the same helicopter the man was in? and you answer: no. Or yes. Then we think again and ask another questions...
 
Sahir Shibley
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Its gone now. How about some more puzzles.
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ha! You should better not ask me.
Imagine yourself in jail (sorry for that!). You have two guards, one of them always tell the truth, and another always lies (and you do not know which of them). Your ward has two doors: one leaves to freedom, another, naturally, to the scaffold (sorry again!). You can ask only one question and your guards will answer yes or no. Which question you should ask if you decided to choose freedom?
Are you glad that you asked ?
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I won't comment on Map's latest, since I've heard it before.
Stevie: are the distances of 100 and 200 meters measured vertically, increasing in the upward direction? I.e. is 200 m a position 100 m above the 100m position? (I know, it seems obvious - but it's useful to check unstated assumptions in these problems...)
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, Jim, to keep you busy here is one more, hopefuly you do not know it.
You are so sick that your doctor made you to take 2 pills every day: one from bottle "A" and another from "B". Everything was OK until one day you mistakenly took two pills out of B bottle. Now you have 3 pills, one from A and two from B bottles which all look the same. Oh, almost forgot, if you eat more than one pill from any bottle you immediately die. (I wonder why logic puzzles are so blood-thirsty )
Anyway, your challenge is to minimize losses.
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here is another, easier
Two boxes, A and B, have signs. Sign on A says "sign on box B is right and gold is in box A". Sign on B box says: "sign on A is wrong and gold is in box A". There is gold in one of boxes, question is in which.
You see how nice Map is ��� you even have a chance to survive in this one
 
Stevie Kaligis
Ranch Hand
Posts: 400
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

by Jim :
Stevie: are the distances of 100 and 200 meters measured Vertically, increasing in the upward direction? I.e. is 200 m a position 100 m above the 100m position? (I know, it seems obvious - but it's useful to check unstated assumptions in these problems...)


YES !
 
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Mapraputa Is:
take 2 pills every day...


I would just throw away all the three pills, and take a fresh one from A, and one from B (those damn pills may be expensive, but I value my life most!)
Or, if there's one question I can ask one pill, what would that be? (Now i am getting all the puzzles mixed up.) Remember that the A bottle pills always lie, and the B bottle pills always tell the truth. (To make it easy, A & B pills can identify each other, even though you cannot!)
Map, you got the strange characters again, shown here in bold:

...how nice Map is ��� you even have...


 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would just throw away all the three pills, and take a fresh one from A, and one from B
Yeah! That was my first reaction too! But there is better decision.
Unfortunately pills are not going to help you, but frankly, you do not need their help!
Map, you got the strange characters again
Something mysterious going on here... I can see that strange sign now, but I can swear it was not here when I posted my message � I checked! Even more, since I was caught with using mysterious symbols, I started to pay attention to other guys posts, and immediately discovered one post where ' sign was absent. It could be seen in source HTML but browser diplayed it as a blank. Few minutes ago I looked at that post and now there is a strange symbol too, although post was not edited. Myself continue observations.
 
Sahir Shibley
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The prison door problem.
You point to one of the doors and ask a guard "If I ask the other guard if this is the door to freedom will he say yes? "
If its the right door you will get the answer no from both guards and if its the wrong door both guards will answer yes.
[This message has been edited by Sahir Shibley (edited May 01, 2001).]
 
Ranch Hand
Posts: 3143
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The prison problem sounds a bit like a scene in "Labrynth" .. love that film ... Sahir's solutions looks right to me.
 
Nanhesru Ningyake
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Mapraputa Is:
Something mysterious going on here... I can see that strange sign now, but I can swear it was not here when I posted my message


This must be the Mark Of Map, like the Mark of Zorro
 
Sahir Shibley
Ranch Hand
Posts: 275
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Mapraputa Is:
Something mysterious going on here...


Strange hieroglyphics in Java Ranch posts
Mystery surrounds the sudden appearance of strange hieroglyphics in the Java Ranch Meaningless Drivel forum. All of them have been sighted in posts by Mapraputa, a Java Ranch diva. Is this the ancient curse of Amen-ra ? Is Map the victim of a giant conspiracy ? Speculation is rife. Meanwhile, your correspondent at the scene of the crime continues to be baffled by the pill puzzle. Find out more in the next edition of "THE MAP CONSPIRACY ".


[This message has been edited by Sahir Shibley (edited May 01, 2001).]
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The pill problem: take one more pill from A. Group it with the other three. Divide all 4 pills in half with a knife or something. (Of course, this won't work if they have liquid centers, but let's assume they don't.) Take first half of each pill one day, and second half of each pill the next day. Go find the lawyer from the first problem and sue the drug company for providing potentially lethal pills without any distinguishing marks on them. Thanks to massive amount of money from lawsuit, you (a) don't really need the gold in one of the boxes, (b) can probably bribe your prison guards, (c) can buy a new helicopter, and (d) can buy a proper Western-made computer which doesn't try to insert any weird Cyrillic characters into your posts.
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For the 2 boxes and gold problem: OK, start with the (unstated) assumption that all statements must be either true or false. (This assumption is the root of all evil an most paradox problems; it isn't true in the real world of course, but it's necessary in order to generate paradoxes, so I assume you want us to make it.) But since both statements are compound statements linked by "and", a statement can be false overall even if one of its substatements is true.
If the gold were in box a, then the latter half of each statement would be true, and the remaining statements reduce to A: "Sign B is right." B: "Sign A is wrong." This of course is a paradox - there's no possible way to assign boolean true/false values to these statements. So if we're determined to keep the original assumption that statements must be either true or false, we must discard the other assumption: the gold cannot be in box A.
To verify: if the gold is in box B, then the second half of each statement is false, and thus each statment is false (even though the first part of sign B is true). This is a logically consistent state which allows us to keep the original assumption about boolean values. So the gold must be in box B.
 
Ranch Hand
Posts: 316
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Some of you, especially Stevie, ought to check out www.lateralpuzzles.com if you haven't done so already.
Paul R
 
Ranch Hand
Posts: 301
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This one is probably too easy for you geniuses...
You have 6 bars of gold and a weight/balance (think the blind statue of Justice). One bar is fake and thus weighs less than the other five. Using the balance only twice, how do you determine which bar is fake?
Then there are questions like: "Yes or No, have you stopped beating your wife yet?"
And of course the classic pay attention questions:
1: If a plane crashed in the Rio Grande, exactly on the border between Mexico and Canada, where would you bury the survivors?
2: Is it legal in Colorado for a man to marry his widow's sister?
3: How many months have 28 days?
And my all-time favorite:
If a train left Chicago traveling west at 45mph, and another train left San Francisco traveling east at 63mph, how many apples can you buy for a dollar?

------------------
I'm a soldier in the NetScape Wars...
Joel
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ah Sahir... Never was Map so close to disclosure...
If to be serious, Map is mystified herself. Look at her message April 28, 11:37pm, the last paragraph! You see - Map did not edit it and there are three wrong symbols there! I can guess that she used wrong symbol for ", but not three wrong symbols! Now there are three wrong! They propagate!
As to puzzles, Sahir's and Jim are, of course, right.
I like these puzzles because it's a funny illustration of boolean algebra (expect one with pills ). I wonder why our professors never used such games... Their lectures could be more entertaining, I suppose.
Puzzle with boxed gold was too easy for programmers, of course, but it should be good for students who study logic.
Ok, now Map's last puzzle. What is about it - you can adjust level of hardess according to your own preferences. I read that there were about 10 different answers, based on how hard people think
Ok, one company had 100 working Java programmers. One day
Chief of Software Department proclaimed that the company has to fire some programmers. To decide who will be fired, he proposed the following schema. All 100 programmers will form a column, so everybody can see those who before but not those behind. (the first one can see nobody, the last programmer can see everybody, except himself). All programmers have caps on their head which can be white, red or black. Each minute one of programmers has to tell color of his/her cap. If more than one programmer tell something, all 100 will be fired, the same if nobody tell anything. After all 100 programmers tell something, all who guessed their color wrong will be fired.
Before the procedure started, programmers had a meeting to discuss what they can do to to keep as many of them as possible. (assume that all programmers still want to work on this company even after such an innovative procedure).
Question: how many programmers will be fired?
Paul, thanks for the link, it's interesting! (I hope nobody will find the last puzzle there )
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ummm... I think the rules need clarification first...
> If more than one programmer tell something, all 100 will
> be fired
> After all 100 programmers tell something, all who guessed
> their color wrong will be fired.
The first statement is inconsistent with the second (as well as with other parts of the problem.) What did you mean here?
 
Mapraputa Is
Leverager of our synergies
Posts: 10065
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok,
If more than one programmer tell something at the same time, all 100 will be fired
Quite frankly, I also do not understand why this rule is so important (such a tragic consequences ) and why would programmers want to tell something simultaneously.
I think we can simplify it by saying that programmers should tell their colors one after another, so everybody get chance to say something. But there is no predefined order. Of course, if some of them prefer to keep silence � it is also possible, except they apparently will be fired.
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OK. Assign numeric values to all colors: white = 0, red = 1, black = 2. Everyone in the line looks at all the people ahead of him/her self, adds up the numeric values of all the colored hats, divides by 3 and remembers the remainder - call this R(i) for the ith person from the start of the line. Programmer 99 simply converts R(99) back to the corresponding color and says that color as his guess. He has a 1/3 chance that this is the correct guess for him. Programmer 98 now knows the value of R(99), and already knew the value of R(98). The difference between these corresponds to the color of his hat, which he then says aloud. Then 97 has enough info to know the color of his hat, and says it, and so on, up to programmer 0. In general, programmer i must calculate his color C(i) using
C(i) = ( R(99) - C(98) - C(97) ... - C(i+1) - R(i) + 300 ) % 3
Note - the + 300 is just there to ensure that the result is positive; there are plenty of other ways to achieve this, but this seemed simplest.
Assuming everyone is trustworthy in this plan and there are no errors, 99 programmers can keep their jobs, and one (#99) has a 2/3 chance of losing it. Of course, since everyone else needs the data that #99 provides, it's in their interest to offer #99 a nice cash bribe in case he loses his job. I don't want to think about what happens if one person screws up, or if a subgroup of programmers decides to cut the remaining programmers out of the company by bribing the next programmer to give a wrong answer. What if the company added a rule that there must be at least 10 programmers let go, and if that didn't happen then everyone would be fired? It could get ugly.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic