Yes, of course. It sounds like the best thing for you to do is to read an introductory book on how to work with Mathematica and what it can do. I would recommend that this should be your next step.
The answer to your particular question:
Expand[(1 + x)^2] == x^2 + 2 x + 1
returns
True