C calls out that he has a black hat.
He is certain because D sees that both B & C have a white and black hat respectively. This shows that D doesn't know what color his hat was. If he knew, then both would have white hats on. Since D says nothing, D doesn't know what color the hat is. C can see that B has a white hat, so C's hat must be black.
He is certain because D sees that both B & C have a white and black hat respectively. This shows that D doesn't know what color his hat was. If he knew, then both would have white hats on. Since D says nothing, D doesn't know what color the hat is. C can see that B has a white hat, so C's hat must be black.