TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: What are your favorite brain teasers?

6 点作者 huangm超过 15 年前
The other day I encountered an interesting problem: <i>You have two fair, six-sided die with positive-integer-valued faces. You roll the die, and take the sum S of the numbers you roll. S will have some frequency distribution. For standard die, theres 1 way to roll a 2, 2 ways to roll a 3, etc. Are there any other pairs of die (the dice need not be identical) that generate this same frequency distribution?</i><p>It turns out this problem has a unique solution, and a nice name: http://en.wikipedia.org/wiki/Sicherman_dice<p>I encounter pretty cool problems like this on a regular basis, but they are always by way of a random friend or blog post - there doesn't seem to be a good central resource for such things. This may be because any problem that enough people know about is no longer novel or interesting (think of all the tired brainteasers you know of).<p>Nonetheless, I'd be interested to hear of other peoples' fun brain teasers. What are some of your favorites?

1 comment

rottencupcakes超过 15 年前
This one's my favorite. Good luck. I'll buy a 6-pack for the first person to solve it:<p><i>A hundred prisoners are each locked in a room with three pirates, one of whom will walk the plank in the morning. Each prisoner has 10 bottles of wine, one of which has been poisoned; and each pirate has 12 coins, one of which is counterfeit and weighs either more or less than a genuine coin. In the room is a single switch, which the prisoner may either leave as it is, or flip. Before being led into the rooms, the prisoners are all made to wear either a red hat or a blue hat; they can see all the other prisoners' hats, but not their own. Meanwhile, a six-digit prime number of monkeys multiply until their digits reverse, then all have to get across a river using a canoe that can hold at most two monkeys at a time. But half the monkeys always lie and the other half always tell the truth. Given that the Nth prisoner knows that one of the monkeys doesn't know that a pirate doesn't know the product of two numbers between 1 and 100 without knowing that the N+1th prisoner has flipped the switch in his room or not after having determined which bottle of wine was poisoned and what color his hat is, what is the solution to this puzzle?</i>
评论 #906724 未加载
评论 #907225 未加载
评论 #906533 未加载