Riddle #744

logic

Stop fighting

Sally and her younger brother were fighting. Their mother was tired of the fighting, and decided to punish them by making them stand on the same piece of newspaper in such a way that they couldn't touch each other. How did she accomplish this?
Sally's mother slid a newspaper under a door and made Sally stand on one side of the door and her brother on the other.
93.22 %
37 votes

Similar riddles

See also best riddles or new riddles.

logicshort

How many T’s

Tommy Tucker took two strings and tied two turtles to two tall trees. How many T’s in that?
There are 2 t’s in THAT.
93.39 %
38 votes

logic

Same Number of Handshakes

At a dinner party, many of the guests exchange greetings by shaking hands with each other while they wait for the host to finish cooking. After all this handshaking, the host, who didn't take part in or see any of the handshaking, gets everybody's attention and says: "I know for a fact that at least two people at this party shook the same number of other people's hands." How could the host know this? Note that nobody shakes his or her own hand.
Assume there are N people at the party. Note that the least number of people that someone could shake hands with is 0, and the most someone could shake hands with is N-1 (which would mean that they shook hands with every other person). Now, if everyone at the party really were to have shaken hands with a different number of people, then that means somone must have shaken hands with 0 people, someone must have shaken hands with 1 person, and so on, all the way up to someone who must have shaken hands with N-1 people. This is the only possible scenario, since there are N people at the party and N different numbers of possible people to shake hands with (all the numbers between 0 and N-1 inclusive). But this situation isn't possible, because there can't be both a person who shook hands with 0 people (call him Person 0) and a person who shook hands with N-1 people (call him Person N-1). This is because Person 0 shook hands with nobody (and thus didn't shake hands with Person N-1), but Person N-1 shook hands with everybody (and thus did shake hands with Person 0). This is clearly a contradiction, and thus two of the people at the party must have shaken hands with the same number of people.
93.39 %
38 votes

funnylogicshort

Volume of the pizza

If you had a pizza with crust thickness 'a' and radius 'z', what's the volume of the pizza?
pi * z * z * a
92.67 %
34 votes

logic

Monk on a Path

A monk leaves at sunrise and walks on a path from the front door of his monastery to the top of a nearby mountain. He arrives at the mountain summit exactly at sundown. The next day, he rises again at sunrise and descends down to his monastery, following the same path that he took up the mountain. Assuming sunrise and sunset occured at the same time on each of the two days, prove that the monk must have been at some spot on the path at the same exact time on both days.
Imagine that instead of the same monk walking down the mountain on the second day, that it was actually a different monk. Let's call the monk who walked up the mountain monk A, and the monk who walked down the mountain monk B. Now pretend that instead of walking down the mountain on the second day, monk B actually walked down the mountain on the first day (the same day monk A walks up the mountain). Monk A and monk B will walk past each other at some point on their walks. This moment when they cross paths is the time of day at which the actual monk was at the same point on both days. Because in the new scenario monk A and monk B MUST cross paths, this moment must exist.
93.98 %
42 votes

interviewlogic

Which came first into the wolrd, the chicken or the egg?

One day a scholar came to the court of Emperor Akbar and challenged Birbal to answer his questions and thus prove that he was as clever as people said he was. He asked Birbal: "Would you prefer to answer a hundred easy questions or just a single difficult one?" Both the emperor and Birbal had had a difficult day and were impatient to leave. "Ask me one difficult question," said Birbal. "Well, then tell me," said the man, "which came first into the world, the chicken or the egg?" "The chicken," replied Birbal, very confidently. "How do you know?" asked the scholar, a note of triumph in his voice. What did Birbal answer to this?
Birbal told the scholar, "We had agreed you would ask only one question and you have already asked it" and he and the emperor walked away leaving the scholar gaping.
93.84 %
41 votes

logicmath

Anagram Checker

Two words are anagrams if and only if they contain the exact same letters with the exact same frequency (for example, "name" and "mean" are anagrams, but "red" and "deer" are not). Given two strings S1 and S2, which each only contain the lowercase letters a through z, write a program to determine if S1 and S2 are anagrams. The program must have a running time of O(n + m), where n and m are the lengths of S1 and S2, respectively, and it must have O(1) (constant) space usage.
First create an array A of length 26, representing the counts of each letter of the alphabet, with each value initialized to 0. Iterate through each character in S1 and add 1 to the corresponding entry in A. Once this iteration is complete, A will contain the counts for the letters in S1. Then, iterate through each character in S2, and subtract 1 from each corresponding entry in A. Now, if the each entry in A is 0, then S1 and S2 are anagrams; otherwise, S1 and S2 aren't anagrams. Here is pseudocode for the procedure that was described: def areAnagrams(S1, S2) A = new Array(26) A.initializeValues(0) for each character in S1 arrayIndex = mapCharacterToNumber(character) //maps "a" to 0, "b" to 1, "c" to 2, etc... A[arrayIndex] += 1 end for each character in S2 arrayIndex = mapCharacterToNumber(character) A[arrayIndex] -= 1 end for (i = 0; i < 26; i++) if A[i] != 0 return false end end return true end
93.55 %
39 votes

funnylogic

Prize of one million pounds

"Welcome back to the show. Before the break, Mr Ixolite here made it to our grand finale! How do you feel Mr.Ix?" "Nervous." "Okay, now to win the star prize of one million pounds all you have to do is answer the following question in 90 seconds." "Okay, I'm ready." "Right. In 90 seconds name 100 words that do NOT contain the letter 'A'. Start the clock!" Can you help?
One, two, three, four, five...one hundred! I just counted from 1 to 100 in ninety seconds (it is possible).
93.39 %
38 votes

cleanlogicshort

Brown house

In a one storey brown house, there was a brown person with a brown computer, brown telephone, and brown chair. He also had a brown cat and a brown fish – Just about everything was brown – What colour was the stairs?
As it was a one-storey house – there were no stairs.
93.39 %
38 votes