Code One-Liner

3 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From Ben via a dead link:

history | awk '{a[$2]++}END{for(i in a){print a[i] " " i}}' | sort -rn | head

What does this one-line shell command do, and how exactly does it do it?

3 Answers. Post Your Answer!

Someone Take This Shovel Out Of My Hands

4 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From Julio Sepia:

It takes one day for ten workers to dig ten holes.
It takes two days for five workers to dig ten holes.

How much does it take for one man to dig HALF a hole?

4 Answers. Post Your Answer!

Chmod Math

8 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From Julio Sepia:

Write the number 755 as the sum of five consecutive odd numbers.

8 Answers. Post Your Answer!

Desert Tracks

10 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From Andreas Renberg:

A large caravan is stuck in the desert. They have enough food and water to last them a while, but still need to send someone to find help.

The nearest city is a 7 day journey, but each person is only able to carry 4 days worth of food.

What do they do so that everyone gets out alive?

10 Answers. Post Your Answer!

Which Switch?

16 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From Sean Murphy:

There are 1000 switches numbered from 1 to 1000. They are all off. I begin by flicking all the switches. I then flick every second switch (2,4,6…). I then flick every third switch (3,6,9…). I repeat the process 1000 times.

How many switches are off by the time I have finished?

16 Answers. Post Your Answer!

Lie Detector

13 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From fretje:

When you die, you go to this place where there are two doors: one goes to heaven, the other one goes to hell. There’s a guard in front of each door. You don’t know which door is which. The only thing you know is that one of the guards is always telling the truth, while the other one is always lying. You can ask one question to one of the guards.

How do you know which door to take to get to heaven?

13 Answers. Post Your Answer!

Bomb Planning

16 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

From asas:

You have two 4 min fuses and a bomb. You want to be able to time the detonation of the bomb for 1min. Like the ropes puzzle, neither fuse burns at a uniform rate throughout.

How do you time your act of senseless destruction?

16 Answers. Post Your Answer!

Time Angles

17 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

The setup for this puzzler is quite simple.  You have an ordinary clock and the time is exactly 3:15 pm.

What is the angle between the two hands of the clock?

17 Answers. Post Your Answer!

Circular Quarters

14 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

You are playing a game with your friend sitting across a perfectly round tabletop. You each have a supply of quarters which you will place on the table one at a time, without moving any other quarters and without overlapping. The last person who successfully puts a quarter on the table without running out of space on the table wins the game. You get the lucky break of going first.

Where should you put your quarter to ensure that you win, and why?

[Bonus Round] You don’t get to go first.  Depending on where your partner puts his quarter first, where do you put your quarter second to best your odds?  Can you guarantee a win or a stalemate?

14 Answers. Post Your Answer!

Burning Ropes

31 Answers   Challenge Your Friends Challenge Your Friends   Tweet this

You have a large selection of ropes of varying lengths. The ropes burn at different rates, even one part of a rope may burn differently than another part, but there’s no way to tell just by looking at them. What you do know is that every single rope will take exactly 1 hour to burn from one end to the other. You also have access to matches, but nothing else (obviously no clocks, etc).

How can you time exactly 30 minutes using the ropes?

31 Answers. Post Your Answer!