From Edge:
When children turn four, they start to wonder what other people are thinking. For instance, if you show a four-year-old a packet of gum and ask what's inside, she'll say, “Gum.” You open the packet and show her that inside there's a pencil instead of gum. If you ask her what her mother, who's waiting outside, will think is in the packet once it's been reclosed, she'll say, “Gum,” because she knows her mother hasn't seen the pencil. But children under the age of four will generally say their mother will think there's a pencil inside — because children this young cannot yet escape the pull of the real world. They think everyone knows what they know,
because they cannot model someone else's mind and in this case realize that someone must see something in order to know it. This ability to think about what others are thinking about is called having a theory of mind.Humans constantly want to know what others are thinking: Did he see me glance at him? Does that beautiful woman want to approach me? Does my boss know I was not at my desk? A theory of mind allows for complex social behaviors, such as military strategies, and the formation of institutions, such as governments.
More here.