Puzzles/Logic puzzles/3 Hats in a Circle

Puzzles | Logic puzzles | 3 Hats in a Circle

Three men, who are not wearing glasses, are placed in a room without mirrors. A hat, which they cannot see, is placed on each of their heads. The hat is either red or green in color. They are not allowed to inspect their own hats in any way and are forbidden to talk or communicate in any way except as follows: if they see a red hat, they are to raise their right hand. If they figure out what colour their own hat is, they are to leave the room immediately without a word to anyone. They must stay in the room until they figure out what colour their own hat is, or until someone else does. After about ten minutes, one of the men figures it out and leaves the room. As it turns out, all the hats are red.

How did he figure out what colour his own hat was?