Log In

Monthly Archives for June, 2013

Red paint vs Blue paint

Posted on: June 30th, 2013 by
Comments Disabled
What is red and smells like blue paint? SPOILER WARNING ... ... ... ... ... via Best Brain Teasers

Find the next number in the sequence

Posted on: June 29th, 2013 by

1 11 21 1211 111221 312211 13112221 ? via Idoia

Binary expression tree

Posted on: June 28th, 2013 by
Comments Disabled
Is there any way to algorithmically determine if two algebraic expressions are equivalent? For example is 5+x equal to x+5? Or how will a computer know (a+b)^2=a^2+2ab+b^2? Does the figure below give you a hint? Binary tree Brought to my attention by Shaleen. The original question can be found on Stack Overflow.

An algorithmic puzzle

Posted on: June 27th, 2013 by
Comments Disabled
Suppose you have an array of size n+1, each entry being an integer from 1 to n. Find a duplicate entry in linear time using only O(1) (constant) space. via Gurmeet's puzzle page

Integer programming

Posted on: June 26th, 2013 by
Comments Disabled
3 objects A,B and C together cost 50 cents. B costs more than 3 times as much as A, but no more than 4 times as much. C costs more than 6 times as much as A, but no more than 3 times as much as B. The costs are all integers. What are the smallest and largest prices that B can take? This is an example of integer Continue reading the story "Integer programming"

Skyscraper puzzle

Posted on: June 25th, 2013 by
Comments Disabled
Here is a link to what are called skyscrapper puzzles. The puzzle consists of a rectangular grid of dimensions n x n. Each row and column is to be filled with numbers from 1 to n so that all numbers occur in each row/column exactly once. These numbers represent building heights. Another constraint is the number of buildings that can be seen from the Continue reading the story "Skyscraper puzzle"

Mirror guns

Posted on: June 24th, 2013 by

You find yourself in a rectangular room with Osama Bin Laden. Osama has a laser pistol to fire you. The 4 walls of the room are perfectly reflecting mirrors. Osama is about to shoot you either directly or through the mirror. The only way you can save yourself is by placing 16 bodyguards with shields in the room so that any shot from Osama to Continue reading the story "Mirror guns"

A betting game

Posted on: June 23rd, 2013 by
Comments Disabled
There are two urns. Each urn initially contains $1. You keep throwing dollars into the urns 1 dollar at a time, until the 2 urns together contain 1 million dollars. Except, you bias the probability as follows: Suppose urn 1 contains $a and urn 2 contains $b, then the extra urn goes to urn 1 with probability a/(a+b). Thus the urns are slightly magnetic, the urn with Continue reading the story "A betting game"

Passing a cube through a smaller cube

Posted on: June 22nd, 2013 by
Comments Disabled
Can you pass a large cube through a hole in a smaller cube so that the larger cube passes and comes out through the other side of the hole? Surprisingly (and of course, since I asked this puzzle) the answer is YES! - via Peter Winkler's video here

Read More About this Post Here

Posted on: June 21st, 2013 by

Find a nine digit number abcdefghi that uses all the digits 1,2,3,...9 exactly once and satisfies: a is divisible by 1 ab (2 digit number with digits a and b) is divisible by 2 abc (3 digit number with digits a, b and c) is divisible by 3 ....... ....... abcdefghi is divisible by 9. via singingbanana through youtube

{"result":"error", "message":"You can't access this resource as it requires an 'view' access for the website id = 1."}