There were four men buried up to their neck in sand
with a brick wall between man A and B.

A is looking at the brick wall.

B can only see the brick wall.

C can only see B.

D can only see C and B.

In other words B,C,D are looking in the same direction towards the wall.
A is looking in the opposite direction towards the wall.

They are not permitted to talk to each other, but they can hear each other's replies to the question, and tell where those replies are coming from.

All four men know how many hats there are - two black and two white.

The executioner will execute all four of them unless one of the four buried men tells him what colour hat he is wearing. (not the executioner's hat colour!!)

Which man? and how did you come to the answer?

I give up, please email me the solution

www.liquidsky.net