instruction
stringlengths
15
30k
##The Magic Hexagon Problem## ![Magic Hexagon][1] > A magic hexagon of order n is an arrangement of close-packed hexagons containing the numbers 1, 2, ..., H_(n-1), where H_n is the nth hex number such that the numbers along each straight line add up to the same sum. (Here, the hex numbers are i.e., 1, 7, 19, 37,...
One solution is to reverse the subject of puzzle. Instead of focusing on the father who is withholding an important detail, make it about the strategy of teasing out information. Here's my attempt: > Last weekend our Parents of Twins Club had a father-daughter night at the ballet. Since he wasn't invited, my twin b...
> Mr. Smith has two children. **Mr. Smith only tells you that** at least one of them is a boy, **but does not tell you anything else about them. Ceteris paribus,** what is the probability that both children are boys? I have added the part in bold, and this rids the problem of ambiguity. Mr. Smith has told you that, ...
20 teams played a round robin tournament. The winner of each game got 1 point, the loser none, there were no draws. Each team's total score was a square number.How many upsets were there, defined as times a team with a lower total score beat a team with a higher total score? Source: New Scientist Enigma column, lon...
Here's a third puzzle that I found in a book, slightly paraphrased since the original seemed to involve vitamin C and it's not really relevant to the heart of the puzzle. > A medical researcher is trying to test the effect of a certain drug on mice. He is supposed to collect data for all doses from 1 to 50 units, bu...
Here's a third puzzle that I found in a book, slightly paraphrased because I don't entirely remember the format of the original. > A medical researcher is trying to test the effect of a certain drug on mice. He is supposed to collect data for all doses from 1 to 50 units, but only has the data collection resources f...
Alternative solution (?) >! Lay the ropes next to each other and light each rope at opposing ends. WHen the flames meet in the middle, 30mins has passed. Then move the ropes so the unburnt sections are next to each other, when the flames meet again, 15mins has passed - hence 45mins.
A group of N pirates has come by a chest containing 200 gold coins. Their rules require that the coins be distributed by the following approach. The pirates are ranked from fiercest to meekest and all pirates know the ranking. The fiercest must propose a division, which is put to majority vote with the fiercest voti...
There is another way to do this problem, that doesn't involve any sort of conditional branching at all. It is in fact possible to set a fixed weighing schedule beforehand and still determine which ball is lighter or heavier in just 3 weighings. I'll explain how below. ----- The gist of problems like these is, how...
Here's a neat little puzzle taken from a Google interview question: >10 humans are abducted by aliens; each represents 10% of the entire human population. The aliens give each abductee either a purple hat or a green hat. The 10 are lined up in a single file line, each facing forward, such that the last person can se...
The question of [twelve balls and a scale](http://puzzling.stackexchange.com/questions/183/twelve-balls-and-a-scale) is probably the best-known example of the "find the ball of a different weight" problem. But does it generalize? Is there a general way to find a weighing algorithm for `N` balls on a scale where `N ≠ 12...
Here's a neat little puzzle taken from a Google interview question: >10 humans are abducted by aliens; each represents 10% of the entire human population. The aliens give each abductee either a purple hat or a green hat. The 10 are lined up in a single file line, each facing forward, such that the last person can se...
I think this would work? Sorry if it's confusing. I sort of confused myself when I came to this conclusion. The first guy would count the number of hats before him of a particular color... like, I dunno, I guess purple? And if the count of purple hats is odd, then he would say that his hat is purple. But if the coun...
#Red or Black There are 3 children sitting on three chairs. The children can only look forward and all wear one hat. The hats are either black or red. They are a total of 5 hats, 3 are coloured red and 2 are coloured black. The child on chair A says: "I don't know what colour of the hat I have." Then the child on chai...
This problem is commonly cited as a Microsoft interview problem, although I have paraphrased it here to involve a river and a boat instead of a bridge and a flashlight, and tweaked the crossing times a little bit. > There are four people standing on one side of a river, and they need to cross it as quickly as possib...
I think this would work? Sorry if it's confusing. I sort of confused myself when I came to this conclusion. The first guy would count the number of hats before him of a particular color... like, I dunno, I guess purple? And if the count of purple hats is odd, then he would say that his hat is purple. But if the coun...
MathJax-version of this post. See below for the raw: ![MathJax colors & hats][1] ---- Generically, what do you do if there are $c$ colors, and $n$ people? Imagine further the aliens say the following: > You can plan your strategy now, but we are only going to tell you what the colors are going to be (includ...
Let's put the number of coins at C and see what happens if we increase N. We'll number the pirates from meekest (1) to fiercest (N). N = 1 1: C + N = 2 1: 0 - 2: C * N = 3 1: 1 + 2: 0 - 3: C-1 + N = 4 1: 0 ...
There are three cowboys in a Mexican standoff against each other, named Juan, José, and Jorge. - Juan is the straightest shooter in the West, and can hit his target 100% of the time. - José, who has a cataract and can't see clearly, can hit his target 70% of the time. - Jorge, who has no aim but is very clever, ca...
Suppose you have a checkerboard with two opposite corner squares removed, like this: ![mutilated chessboard][1] Can you move a pawn on the board only horizontally and vertically, one square at a time, and have it touch every square exactly once? [1]: https://i.stack.imgur.com/AEqI3.gif
Suppose you have a checkerboard with two opposite corner squares removed, like this: ![Mutilated chessboard][1] Is it possible to place 31 dominoes of size 2x1 so as to cover all of these squares? [1]: https://i.stack.imgur.com/Ln6nc.gif
The puzzle below features each week in a TV guide. It's called "Number Workout" there but I've done a bit of research and it seems to be called "Hexanum" elsewhere. It bears some resemblance to Sudoku, in that it's a logic puzzle with a single solution. ![Hexanum][1] *Transcription: "Fit the numbers 1-6 once in e...
Are there 'Hexanum' puzzles that require advanced methods to solve?
- Juan's strategy is simple: if he has to choose between opponents, then his shot *will* turn it into a two-man contest, and he will have to survive a shot before he can kill the second man. So of course he will shoot Jose first. - José's strategy, similarly, is to shoot at Juan. Leaving Juan alive and Jorge dead ca...
Let's approach this for a purely Game-theory perspective (which means, everyone simply wants to get the biggest possible payout, to live, and no one does actions like shooting someone out of revenge for shooting them, etc.) We can deduce two things logically from the beginning. The first is that since Juan is such a...
Three world powers have just entered a nuclear war! They have been waiting for this day for decades; everyone has their nuclear missiles ready to fire, and only need to choose a target. * **The Chinese** missiles are _Made in China_, and therefore only hit their target **30%** of the time (if that). * **The Am...
Let's approach this for a purely Game-theory perspective (which means, everyone simply wants to get the biggest possible payout, to live, and no one does actions like shooting someone out of revenge for shooting them, etc.) We can deduce two things logically from the beginning. The first is that since Juan is such a...
Three world powers have just entered a nuclear war! They have been waiting for this day for decades; everyone has their nuclear missiles ready to fire, and only need to choose a target. * **The Chinese** missiles are target **30%** of the time. * **The American** missiles hit their target **60%** of the time....
Three world powers have just entered a nuclear war! They have been waiting for this day for decades; everyone has their nuclear missiles ready to fire, and only need to choose a target. * **The Chinese** missiles hit their target **30%** of the time. * **The American** missiles hit their target **60%** of the...
Let's approach this for a purely Game-theory perspective (which means, everyone simply wants to get the biggest possible payout, to live, and no one does actions like shooting someone out of revenge for shooting them, etc.) We can deduce two things logically from the beginning. The first is that since Juan is such a...
Yes, there is an algorithm. Oh, you wanted to know what the algorithm is? Here is one, which presents an algorithm but not all the reasoning behind it. For that, and a proof, and the variant where the odd ball must be identified but not the direction of its deviance, read [Thomas Pornin's excellent presentation on t...
> **NOTE:** This is in reference to [an existing question](http://puzzling.stackexchange.com/q/252/72) which I feel is poor and off-topic. In the spirit of "shaping the site while in private beta", I wanted show how the question can be re-phrased and "fixed" in order to be more on-topic here. There is a specific S...
Why is this considered to be "The World's Hardest Sudoku"?
- Juan's strategy is simple: if he has to choose between opponents, then his shot *will* turn it into a two-man contest, and he will have to survive a shot before he can kill the second man. So of course he will shoot Jose first. - José's strategy, similarly, is to shoot at Juan. Leaving Juan alive and Jorge dead ca...
Let's approach this for a purely Game-theory perspective (which means, everyone simply wants to get the biggest possible payout, to live, and no one does actions like shooting someone out of revenge for shooting at them, etc.) We can deduce two things logically from the beginning. The first is that since Juan is suc...
Let's put the number of coins at $c$ and see what happens if we increase $n$. We'll number the pirates from meekest ($1$) to fiercest ($n$). $\begin{array}{rrrll} \begin{array}{c}\text{Nr. of pirates}\end{array} & \begin{array}{c}\text{Pirate} \\ \text{meekest to fiercest}\end{array} & \begin{array}{c}\tex...
The question of [twelve balls and a scale](http://puzzling.stackexchange.com/questions/183/twelve-balls-and-a-scale) is probably the best-known example of the "find the ball of a different weight" problem. But does it generalize? Is there a general way to find a weighing algorithm for $N$ balls on a scale where $N \ne ...
It is possible to have a proper Sudoku with one empty block. The trivial (and very boring) example would be a puzzle where all other cells are given. It's impossible to have a proper Sudoku with an empty chute, since units within the chute that are aligned with it, could be swapped around while the puzzle remained v...
What is the maximum number of empty blocks a proper Sudoku can have?
Generically, what do you do if there are $c$ colors, and $n$ people? Imagine further the aliens say the following: > You can plan your strategy now, but we are only going to tell you what the colors are going to be (including their hex representation) and how many there are after you are no longer allowed to communi...
It is possible to have a proper Sudoku with one empty 3x3 'block'. The trivial (and very boring) example would be a puzzle where all other cells are given. It's impossible to have a proper Sudoku with an empty chute (row or column of blocks), since units within the chute that are aligned with it, could be swapped ar...
What is the maximum number of empty 3x3 blocks a proper Sudoku can have?
It is possible to have a proper Sudoku with one empty block (3X3 cells). The trivial (and very boring) example would be a puzzle where all other cells are given. It's impossible to have a proper Sudoku with an empty chute, since units within the chute that are aligned with it, could be swapped around while the puzzl...
What is the maximum number of empty blocks a proper Sudoku can have?
It is possible to have a proper Sudoku with one empty block (consisting of 3x3 cells). The trivial (and very boring) example would be a puzzle where all other cells are given. It's impossible to have a proper Sudoku with an empty chute, since units within the chute that are aligned with it, could be swapped around w...
What is the maximum number of empty 3x3 blocks a proper Sudoku can have?
A logic puzzle is any puzzle that requires some form of logical thinking or planning. For example: > You are in a room with two wizards. One of these wizards always tells the truth, while the other always lies. How do you figure out which does what by asking both of them just one question? The answer is to ask th...
This is an interesting puzzle which was passed to me by a friend some time ago. I do know the answer, but will refrain from self-answering on this to see where it goes. I'm thinking of a number: 1, 2, or 3. You may ask me one question, which I will answer to the best of my ability. I may not, however, tell you my nu...
This is an interesting puzzle which was passed to me by a friend some time ago. I do know the answer, but will refrain from self-answering on this to see where it goes. I'm thinking of a number: 1, 2, or 3. You may ask me one question, which I will answer to the best of my ability. I may not, however, tell you my nu...
The question I would ask is this: > If $n$ is your number, is $\frac{n}{n-2}$ positive? The possible answers are: - If $n = 1 \rightarrow \frac{n}{n-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \frac{n}{n-2} = \frac{2}{0}$, so the answer is some form of **"I can't say"**. - If $n = 3 \rightar...
Would it work if I ask: "I'm thinking of a number: either 0 or 1. Is the sum of our numbers greater than 2?" I could figure out the answer if that's a question I'm allowed to ask. If your number is 3, then you would say "yes" because no matter what you add, it would be true. If your number is 2, you would say "I ...
Here's my thought process on this: - The three answer possibilities must be "yes," "no," and... something else. - Perhaps there is a way to get an answer of "maybe" or "sometimes?" - Therefore, this would have to involve some kind of randomness. - The question should be in the form of "Either X or Y is true. Is your n...
Here's my thought process on this: - The three answer possibilities must be "yes," "no," and... something else. - Perhaps there is a way to get an answer of "maybe" or "sometimes?" - Therefore, this would have to involve some kind of randomness. - The question should be in the form of "Either X or Y is true. Is your n...
The question I would ask is this: > If $n$ is your number, is $\frac{n}{n-2}$ positive? The possible answers are: - If $n = 1 \rightarrow \frac{n}{n-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \frac{n}{n-2} = \frac{2}{0}$, so the answer is some form of **"I can't say"**<sup>1</sup>. - If $n ...
We have 1 ball on the table and 0 or 1 balls under a concealed cup. No I ask you is the amount of balls on the table is larger than the number on your mind? 1. No, because 1 is not larger than the 1 or 2 balls on the table 2. Maybe, because maybe it's larger than 1, but it's not larger than 2 3. Yes, because 3...
The question I would ask is this: > If $n$ is your number, is $\frac{n}{n-2}$ positive? The possible answers are: - If $n = 1 \rightarrow \frac{n}{n-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \frac{n}{n-2} = \frac{2}{0}$, so the answer is some form of **"I can't say"**<sup>1</sup>. - If $n ...
The question I would ask is this: > If $n$ is your number, is $\lim_{x \to n} \frac{x}{x-2}$ positive (i.e. greater than $0$)? The possible answers are: - If $n = 1 \rightarrow \frac{1}{1-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \lim_{x \to 2} \frac{x}{x-2}$, could be either $+\infty$ or $...
The question I would ask is this: > If $n$ is your number, is $\lim_{x \to n} \frac{x}{x-2}$ positive (i.e. greater than $0$)? The possible answers are: - If $n = 1 \rightarrow \frac{1}{1-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \lim_{x \to 2} \frac{x}{x-2}$, could be either $+\infty$ or $...
If I wanted to solve a physical Rubik's cube multiple times, for practice, what is the best, most random way, to shuffle the solved cube? The best way I can think is to hold it behind my back and turn randomly until, when I look at it, it _looks_ random enough. Is there a better way?
What is the best method of 'shuffling' a rubik's cube?
The question I would ask is this (where $n$ is the number you are thinking of): > Is $\lim_{x \to n} \frac{x}{x-2} > 0$? The possible answers are: - If $n = 1 \rightarrow \frac{1}{1-2} = -1$, so the answer is **"No"**. - If $n = 2 \rightarrow \lim_{x \to 2} \frac{x}{x-2}$, could be either $+\infty$ or $-\inft...
If I wanted to solve a physical Rubik's cube multiple times, for practice, what is the best, most random way, to scramble the solved cube? The best way I can think is to hold it behind my back and turn randomly until, when I look at it, it _looks_ random enough. Is there a better way?
What is the best method of scrambling a rubik's cube?
The question I would ask is this (where \$n\$ is the number you are thinking of): > Is \$\lim_{x \to n} \frac{x}{x-2} > 0\$? The possible answers are: - If \$n = 1 \rightarrow \frac{1}{1-2} = -1\$, so the answer is **"No"**. - If \$n = 2 \rightarrow \lim_{x \to 2} \frac{x}{x-2}\$, could be either \$+\infty\$ ...
Let's put the number of coins at \$c\$ and see what happens if we increase \$n\$. We'll number the pirates from meekest (\$1\$) to fiercest (\$n\$). \$\begin{array}{rrrll} \begin{array}{c}\text{Nr. of pirates}\end{array} & \begin{array}{c}\text{Pirate} \\ \text{meekest to fiercest}\end{array} & \begin{arra...
Let's put the number of coins at \$c\$ and see what happens if we increase \$n\$. We'll number the pirates from meekest (\$1\$) to fiercest (\$n\$). \$\begin{array}{rrrll} \begin{array}{c}\text{Nr. of pirates}\end{array} & \begin{array}{c}\text{Pirate} \\ \text{meekest to fiercest}\end{array} & \begin{arra...
In single-solution regular Sudoku puzzles, sometimes you may encounter a combination of possible cell solutions such as: - {2,7} in A1 and A7 (same row) - {2,7} in A7 and B8 (same box) - {2,7} in B8 and E8 (same column) - {2,3,5,7} in E1 (same column as A1 and same row as E8) I call patterns like the one a...
Let's put the number of coins at \$c\$ and see what happens if we increase \$n\$. We'll number the pirates from meekest (\$1\$) to fiercest (\$n\$). \$\begin{array}{rrrll} \begin{array}{c}\text{Nr. of pirates}\end{array} & \begin{array}{c}\text{Pirate} \\ \text{meekest to fiercest}\end{array} & \begin{arra...
I've tried to explain the solution using as little math as possible, and to give some intuition as to what makes it tick. Nonetheless there will be a little mathematical notation at the end. ### First steps: going beyond the obvious solution in the simplest case (N=2) The statement of the puzzle as presented here...
As Kendall mentions, it is impossible to move pieces out of a 3x3 grid in this manner. This is called the [Lo Shu square](http://en.wikipedia.org/wiki/Lo_Shu_Square), and is the only unique solution to the 3x3 magic grid puzzle. The reason for this is actually rather simple. If you look at the Lo Shu square, you'll ...
The question of [twelve balls and a scale](http://puzzling.stackexchange.com/questions/183/twelve-balls-and-a-scale) is probably the best-known example of the "find the ball of a different weight" problem. But does it generalize? Is there a general way to find a weighing algorithm for \$N\$ balls on a scale where \$N \...
Generically, what do you do if there are \$c\$ colors, and \$n\$ people? Imagine further the aliens say the following: > You can plan your strategy now, but we are only going to tell you what the colors are going to be (including their hex representation) and how many there are after you are no longer allowed to com...
- Juan's strategy is simple: if he has to choose between opponents, then his shot *will* turn it into a two-man contest, and he will have to survive a shot before he can kill the second man. So of course he will shoot Jose first. - José's strategy, similarly, is to shoot at Juan. Leaving Juan alive and Jorge dead ca...
Yes, there is an algorithm. Oh, you wanted to know what the algorithm is? Here is one, which presents an algorithm but not all the reasoning behind it. For that, and a proof, and the variant where the odd ball must be identified but not the direction of its deviance, read [Thomas Pornin's excellent presentation on t...
##The Magic Hexagon Problem## ![Magic Hexagon][1] > A magic hexagon of order n is an arrangement of close-packed hexagons containing the numbers \$1, 2, ..., H_{n-1}\$, where \$H_n\$ is the n<sup>th</sup> hex number such that the numbers along each straight line add up to the same sum. (Here, the hex numbers are ...
##The Magic Hexagon Problem## ![Magic Hexagon][1] > A magic hexagon of order n is an arrangement of close-packed hexagons containing the numbers \$1, 2, ..., H_{n-1}\$, where \$H_n\$ is the n<sup>th</sup> hex number such that the numbers along each straight line add up to the same sum. (Here, the hex numbers are ...
According to [Wikipedia](http://en.wikipedia.org/wiki/Verbal_arithmetic), Verbal Arithmetic can be defined as "a type of mathematical game consisting of a mathematical equation among unknown numbers, whose digits are represented by letters. The goal is to identify the value of each letter." For example, the problem:...
Two perfect logicians, Summer and Proctor, are told that integers \$x\$ and \$y\$ have been chosen such that \$1 < x < y\$ and \$x+y < 100\$. Summer is given the value \$x+y\$ and Proctor is given the value \$x \cdot y\$. They then have the following conversation. - _Proctor:_ "I cannot determine the two numbers...
According to [Wikipedia](http://en.wikipedia.org/wiki/Verbal_arithmetic), Verbal Arithmetic can be defined as "a type of mathematical game consisting of a mathematical equation among unknown numbers, whose digits are represented by letters. The goal is to identify the value of each letter." For example, the problem:...
When playing [SlitherLink](http://en.wikipedia.org/wiki/Slitherlink) on [moderate][1] or [large][2] boards I usually find that after using the [basic techniques][3]: * filling out the values in the corners * setting lines where there are adjacent 3s * setting lines where there are 3s diagonally (including cases wh...
The [Einstein's puzzle][1] or [zebra puzzle][2] is a well-known logic puzzle. Are there any very easy ways to solve it fast? [1]: http://www.stanford.edu/~laurik/fsmbook/examples/Einstein'sPuzzle.html [2]: http://en.wikipedia.org/wiki/Zebra_Puzzle
Fast strategies for solving Einstein's puzzles?
I, being a fan of 2048, was wondering if anyone has any proven strategies for playing [2048](http://gabrielecirulli.github.io/2048)?
Assuming the game is played without cheating, in [three card monte](https://en.wikipedia.org/wiki/Three-card_Monte) can a logic approach increase the players chance of beating the house? At first glance it would seem to be unlikely but a [recent article in the BBC news](http://www.bbc.com/news/science-environment-27...
In three card monte can a logical principal be applied to increase the odds?
Logic puzzles with a set of conditions and graph, are very popular. More than one publisher is currently producing puzzle books with these types of puzzles. A Wikipedia article claims [Charles Lutwidge Dodgson, (*Lewis Carroll, author of Alice's Adventures in Wonderland.*)](https://en.wikipedia.org/wiki/Logic_prob...
When was the first graph supported logic puzzle published?
Logic puzzles with a set of conditions and a "logic grid" are very popular. More than one publisher is currently producing puzzle books with these types of puzzles. A Wikipedia article claims [Charles Lutwidge Dodgson, (*Lewis Carroll, author of Alice's Adventures in Wonderland.*)](https://en.wikipedia.org/wiki/Lo...
When was the first logic-grid-based puzzle published?
Single player games using a single deck of playing cards often called [patience or solitaire](https://en.wikipedia.org/wiki/Patience_%28game%29), generally involve a degree of skill and luck to solve. With card shuffling ultimately being the deciding factor on if the game can be solved/won. Is there any version of ...
Are there any forms of patience or solitaire that can be solved by logic alone?
![Minesweeper, all blown up][1] [1]: https://i.stack.imgur.com/aELsO.png I was so sure of my decision, but when I double-clicked to clear more cells, the cell to the left of the one I had just flagged (the red one next to the X) was the bomb, and the game ended. Did I have a flaw in my logic, or was this a 50...
How could I have played this Minesweeper game differently?
I always start a Minesweeper puzzle by clicking the cell in the lower left corner. Even though I have never seen a bomb there, how sound is this strategy? Is it possible that some time in the future there will be a bomb there?
Is it always safe to click the lower lefthand corner of a Minesweeper puzzle?
Minesweeper, to those who do not know the strategies involved, is a difficult game. How do I beat it every time, or at least with high frequency?
How do I win minesweeper every time?
There is no way to beat Minesweeper every time - this is just the nature of the puzzle. You will encounter situations where there simply isn't enough information to safely continue, and at this point, your best option is to make a probabalistic guess as to where the mines might be. With that said, there are a couple...
Is it better to start in a corner, edge, or any random middle square? If the first square isn't empty, when is it better to click a neighbor vs. another random square? How does the strategy vary by mine density?
What is the optimal starting strategy in Minesweeper?