Verify the type of a lambda expression I need to verify the type for the lambda expression: $\lambda f.\lambda x.f (f x)$

My method gives me: $(a\rightarrow c)\rightarrow b\rightarrow c$

Im trying to define it in Haskell (on Hugs) like this: 

h= \f x -&gt; f (f x)


When i call the :type comamnd it gives me:

(a -&gt; a) -&gt; a -&gt; a


Is mi function correctly defined in Haskell?, or my method gives me a wrong result?
Haskell is right.

I do not know whether your Haskell syntax is correct, though it looks plausible to me, but the Haskell typing is the right one.

Since $f$ is applied to the result of $f(x)$, $f$ must be of type $a\rightarrow a$,
$a$ being the type of $x$.