This is definitely one of those tricky visualization problems
Imagine just one face of the 5x5 cube. (I'm imagining this massive Rubik's cube
Which of the 1x1 cubes will have paint on only one face? Only those which are not on the
edges - these will share a painted face with another side. The cubes that are not part of the
edge form a 3x3 grouping of 1cm cubes.
Therefore each face has 9 cubes that are painted one color.
Since there are 6 faces we get 6x9 = 54.
Hope that helps!
Magoosh Test Prep