This is all coming from Example 8 in Lecture 2 of Pramod Achar's lecture notes on perverse sheaves.
Let $f: X \to Y$ be a continuous map of any two arbitrary topological spaces, and let $A$ be any abelian group. In general, for $\mathcal F$ a sheaf on $Y$, the pull-back $f^{-1}\mathcal F$ is defined to be the sheafification of the presheaf $\text{ps} f^{-1} \mathcal F$, where for $U \subset X$ open, $$ \text{ps} f^{-1} \mathcal F(U) = \{ \text{equivalence classes of pairs }(V,s)\text{ where }V \supset f(U) \text{ and } s \in \mathcal F (V) \},$$ where the equivalence relation is the same as that for stalks.
The constant sheaf $\underline{A}_X$ is defined by $\underline{A}_X(U) = \{\text{locally constant } g: U \to A\}$ for $U \subset X$ open, and a similar definition for $\underline{A}_Y$. I want to show the following:
There is an isomorphism of sheaves, $f^{-1} \underline{A}_Y \cong \underline{A}_X$.
Since the stalks of a presheaf and its sheafification are isomorphic, I know that to show the above statement it suffices to show that the stalks of $\underline{A}_X$ and $\text{ps} f^{-1} \underline{A}_Y$ are isomorphic, where the stalks are given by $$(\underline{A}_X)_p = \{[U,s] : p \in U, s: U \to A \text{ locally constant}\}$$ and $$(\text{ps} f^{-1} \underline{A}_Y)_p = \{[U, [V,t]] : Y \supset V \supset f(U), U \ni p, t: V \to A \text{ locally constant}\}.$$
To that end, I want to define a morphism of presheaves $F : \text{ps} f^{-1} \underline{A}_Y \to \underline{A}_X$. For $U \subset X$ open, $$ \text{ps} f^{-1} \underline{A}_Y (U) = \{ [V,s] : V \supset f(U), s: V \to A \text{ locally constant}\}, $$ and $$ \underline{A}_X(U) = \{g: U \to A \text{ locally constant}\}.$$ Define $F([V,s]) = s \circ f$, which induces a homomorphism $F_p$ on the stalks given by $$F_p[U, [V,t]] = [U, F_U[V,t]] = [U, t \circ f].$$ Then all I need to do is check that this is in fact an isomorphism, which does not seem so hard.
My question is: is the outline I've given above all correct for showing the statement? There are a lot of definitions involved at the very beginning of learning about sheaves, and I want to check that my understanding is correct. Alternate explanations of the statement would also be helpful - I am familiar with the definition of co/limits and how they relate to the pullback sheaf, but am not so clear on proving things e.g. the above with those definitions.
I'll give an alternate proof which also proves some nice and useful facts about constant sheaves.
Lemma 1 : For any space $X$, let $a_X:X\to\{*\}$ be the unique map to the one point set. Then $\underline{A}_X\simeq a_X^{-1}\underline{A}_{\{*\}}$.
Of course, your assertion immediately implies the above lemma. But it is also equivalent. Indeed : let $f:X\to Y$ be any continuous map, then we obviously have $a_Y\circ f=a_X$, so $f^{-1}\underline{A}_Y\simeq f^{-1}a_Y^{-1}\underline{A}_{\{*\}}\simeq (a_Y\circ f)^{-1}\underline{A}_{\{*\}}=a_X^{-1}\underline{A}_{\{*\}}\simeq\underline{A}_X$.
Now, let us prove the lemma 1. By definition $a_X^{-1}\underline{A}_{\{*\}}$ is the sheafification of the presheaf $\operatorname{ps}a_X^{-1}\underline{A}_{\{*\}}$ which is obviously (recall the definition of $\operatorname{ps}a_X^{-1}$) the constant presheaf $U\mapsto A$ with all restriction maps being the identity. To conclude, it suffices to prove :
Lemma 2 : The constant sheaf $\underline{A}_X$ is the sheafification of the constant presheaf $\underline A^p_X : U\mapsto A$.
To prove this, consider the map $\varphi:\underline A^p_X\to \underline A_X$ such that for any $U\subset X$, $\varphi_U:\underline A^p_X(U)\to \underline A_X(U)$ is the map which sends $a\in \underline A^p_X(U)=A$ to the constant function $f:U\to A$ with value $a$. The lemma 2 is proved if we can show that this induces an isomorphism on stalks. But obviously $(\underline A^p_X)_x=A$ and $(\underline{A}_X)_x$ is also isomorphic to $A$ via the map which send a locally constant function $f$ defined in a neighborhood of $x$ to $f(x)$. And clearly, $\varphi_x$ is the identity with the above identification.