title: How do I find a general type of a haskell definition?
body: <p>How do I determine the types for q2, and q3? The module gave me the types when I enter it in, but what's a reliable method in doing this by hand? Please help. Thank you.</p>
  
  <pre><code>q2 x y z w = w (x y) (z y)
  
  Type is: q2 :: (a -&gt; b) -&gt; a -&gt; (a -&gt; c) -&gt; (b -&gt; c -&gt; d) -&gt; d
  
  q3 f g x y = (f.g) x == y
  
  Type is: q3 :: Eq a =&gt; (b -&gt; a) -&gt; (c -&gt; b) -&gt; c -&gt; a -&gt; Bool
  </code></pre>