fundamental group of $U(n)$ Is my logic correct?
$f:U(n)\rightarrow U(1)$ defined by $f(A)=\det A$ is a group
homomorphism so that the induced homomorphism $f^{*}: \pi_1(U(n))\rightarrow \pi_1(U(1))$ will be an isomorphism, right (I am not sure)? as $\pi_1(U(1))=\mathbb{Z}$ as $U(1)=S^1$
so $\pi_1(U(n))=\mathbb{Z}$.
 A: The map $\mathrm{det}:U(n)\to U(1)\simeq S^1$ is a fiber bundle with fibers diffeomorphic to $\mathrm{SU}(n)$. Since $\mathrm{SU}(n)$ is connected and simply connected, as outlined in Eric Korman's answer, the long exact sequence associated to this fiber bundle provides an isomorphism $\pi_1(\mathrm{U}(n))\simeq \pi_1(S^1)\simeq \mathbb{Z}$.
A: As you saw by your counter example, a Lie group homomorphism does not induce an isomorphism of fundamental groups.  But one way to use homomorphisms to determine fundamental groups is through the fact that if $G$ and $H$ are connected with $G$ simply connected and $G \to H$ is a surjective homomorphism with a discrete kernel $K$ contained in the center of $G$, then this map is a covering and the fundamental group of $H$ is isomorphic to $K$.  So if you know that $SU(n)$ is simply connected then you can consider the homomorphism
$$
SU(n) \times \mathbb R \to U(n), ~~ (A, t) \mapsto e^{it} A.
$$
This is surjective with kernel isomorphic to $\mathbb Z$ so that $\pi_1(U(n)) \simeq \mathbb Z$.
Though I guess the easiest way to see that $SU(n)$ is simply connected is to use Neal's suggestion of applying the LES in homotopy associated to the fibration 
$$SU(n-1) \to SU(n) \to SU(n)/SU(n-1) \simeq S^{2n-1}.$$
But then you might as well compute $\pi_1 U(n)$ directly from the similar fibration
$$U(n-1) \to U(n) \to U(n)/U(n-1) \simeq S^{2n-1}.$$
