TITLE: A manifold with $\pi_1 = \pi_2 = \pi_4 = 0, \pi_3 = \mathbb{Z}$
QUESTION [14 upvotes]: I am looking for an example of a closed connected smooth manifold $M$ with $\pi_1(M) = \pi_2(M) = \pi_4(M) = 0$ and $\pi_3(M) = \mathbb{Z}$, if such a thing exists.
My motivation is to represent the third integral cohomology of a 4-manifold $X$ by (homotopy classes of) maps to some manifold. Since $S^1$ is a $K(\mathbb{Z}, 1)$ and $\mathbb{CP}^\infty$ is a $K(\mathbb{Z}, 2)$, we have $H^1(X ; \mathbb{Z}) = [X, K(\mathbb{Z}, 1)] = [X, S^1]$ and, by cellular approximation, $H^2(X;\mathbb{Z}) = [X, \mathbb{CP}^\infty] = [X, \mathbb{CP}^2]$. So we can represent first and second cohomology of $X$ by maps into manifolds; my question just asks about doing so for the next higher degree. 
Indeed, if we had a manifold $M$ satisfying $\pi_1(M) = \pi_2(M) = \pi_4(M) = 0$, $\pi_3(M) = \mathbb{Z}$, then we could form a $K(\mathbb{Z}, 3)$ from $M$ by attaching 6-cells and higher to kill off $\pi_5$ and higher. So, we would have that the five-skeleta of these two spaces coincide, $M^{(5)} = K(\mathbb{Z}, 3)^{(5)}$, and thus by cellular approximation $$[X, M] = [X, M^{(5)}] = [X, K(\mathbb{Z}, 3)^{(5)}] = [X, K(\mathbb{Z}, 3)] = H^3(X;\mathbb{Z}).$$
If such an $M$ exists, its dimension must be at least 8. Indeed, first observe that $M$ is orientable, since it is simply connected.
All orientable surfaces have trivial $\pi_3$, except for the sphere which has non-trivial $\pi_2$, so that rules out dimension 2. 
Any 2-connected 3-manifold is a homotopy sphere, so this rules out dimension 3 since $\pi_4(S^3) = \mathbb{Z}_2$. 
Hurewicz implies that $H_1(M;\mathbb{Z}) = H_2(M;\mathbb{Z}) = 0$ and $H_3(M;\mathbb{Z}) = \mathbb{Z}$. Poincaré duality now shows that $M$ cannot have dimension 4 or 5. 
Since the Euler characteristic of an oriented $4k+2$ dimensional manifold is even, we can rule out dimension 6 by applying Poincaré duality and computing the Euler characteristic of such an $M$ to be 1. 
Hurewicz also tells us that $\pi_4(M)$ surjects onto $H_4(M;\mathbb{Z})$, so $H_4(M;\mathbb{Z}) = 0$. This rules out $M$ being a 7-manifold because of Poincaré duality again.

REPLY [2 votes]: Let $G$ be a simply connected compact Lie group*. There is a theorem of Bott, see Theorem $21.7$ of Milnor's Morse Theory for example, that shows that $\Omega G$ has the homotopy type of a CW complex with no odd-dimensional cells, and only finitely many cells of each even dimension. It follows that $\pi_2(G) = 0$ and $\pi_3(G)$ is free of finite rank, i.e. $\pi_3(G) \cong \mathbb{Z}^r$ for some $r$. With a little more work, see Bott's An application of the Morse theory to the topology of Lie-groups, one can show that if $G$ is simple, then $\pi_3(G) \cong \mathbb{Z}$.
What about $\pi_4(G)$ for $G$ simple? Theorem IV of Bott & Samelson's Applications of the Theory of Morse to Symmetric Spaces states that there are only two possibilities: $0$ and $\mathbb{Z}_2$. Furthermore, they show that $\pi_4(G) = \mathbb{Z}_2$ if and only if $G = SU(2) = \operatorname{Spin}(3) = Sp(1)$, or $G = Sp(n)$ for $n \geq 2$. By the classification of simple Lie groups, we see that $\pi_4(G) = 0$ if and only if $G$ is one of $SU(n)$ for $n \geq 3$, $\operatorname{Spin}(n)$ for $n \geq 5$, $E_6$, $E_7$, $E_8$, $F_4$, or $G_2$. All of these Lie groups are examples of closed, connected, smooth manifolds with the desired homotopy groups.

*Although it's not needed for your purposes, let me just emphasise that these results hold for all Lie groups. The simply connectedness hypothesis can be removed by passing to the universal cover, and the compactness hypothesis can be removed because every Lie group deformation retracts onto a compact subgroup.