Let the prisoners be named: A(black); WALL; B(white), C(black), D(white)
The middle prisoner in the row of three must know the colour of their hat.
D can see A and B but cannot work out the colour of their hat.
Neither A nor B can see the colour of anyone else's hat.
As D does not say anything, they will all know that B and C are wearing different colour hats. C can see the colour of B's hat and will know they have the other coloured hat.
1960 Views
See similar Oxbridge Preparation Mentoring tutors