Simple exercise in cohomology I know this is a simple exercise but I am stuck unfortunately. 
Question:
Use de Rham cohomology to prove that the sphere $S^2$ is not diffeomorphic to the torus $T$. You may assume that $H^1(\mathbb{R}^2) = \{0\}$. 
Answer: For the sphere $S^2$, one can show that $H^1(S^2) \cong \{0\}$, for the torus one can show that $H^1(T) \cong  \mathbb{R}^2$. Now I don't know how to proceed, what I vaguely understand is that different cohomology implies the manifolds cannot be diffeomorphic. How can I make this precise ? In particular, I must be missing something because I don't know how to make use of the given fact $H^1(\mathbb{R^2}) \cong \{0\}$.
Many thanks for your help!
 A: The de Rham cohomology is functorial in the sense that if you have a smooth map $f: M\to N$ between two manifolds then you have an induced map on the $p$-th cohomology groups
$$ f^*: H^p(M) \to H^p(N)$$
given by the pullback, which is defined on every 1-form $\omega$ by the following formula
$$f^*\omega(X(p)) = \omega(f_*(X(p)))$$
Lemma. Let $M$ and $N$ smooth manifolds and $f: M\to N$ a smooth map then the pullback map $f^*$ sends closed forms on $N$ to closed forms on $M$ and exact forms on $N$ to exact forms on $M$.
The rest is proving the following (easy) properties of the pullback
(1). $(f\circ g)^* = g^* \circ f^* $
 (2). $Id^* = Id $
Now you only have to see that if $f: M\to N$ is a diffeomorphism then $f^*: H^p(M) \to H^p(N)$ is an isomorphism for every $p$. So if $S^1$ and $T$ where isomorphic their $1$-th cohomology groups would also be isomorphic.
Note. You can give another proof using the hint by proving that the cohomology of the torus minus a point is the same as the figure eight cohomology, i.e. $H^1(S^1\vee S^1)\cong \mathbb{R}^2$.
