title: couldn't match expected type (Int -> Int -> Int) with actual type `(t0, t1, t2)'
body: <p>I'm a beginner and I'm trying to do some tutorials on Haskell before entering uni for computer science. </p>
  
  <p>I got stuck in this program. It takes three numbers and puts them in ascending order. Can anyone help me and tell me whats wrong because it's driving me crazy? Thanks for your time.</p>
  
  <pre><code>import Prelude hiding (min,max)
  orderTriple :: (Int -&gt; Int -&gt; Int) -&gt; (Int -&gt; Int -&gt; Int)
  max :: Int -&gt; Int -&gt; Int -&gt; Int
  min :: Int -&gt; Int -&gt; Int -&gt; Int
  middle :: Int -&gt; Int -&gt; Int -&gt; Int
  
  
  max x y z
   |(x&gt;=y) &amp;&amp; (x&gt;=z)  = x
   |(y&gt;=x) &amp;&amp; (y&gt;=z)  = y
   |otherwise     = z
  
  min d e f
   |(d&lt;=e) &amp;&amp; (d&lt;=f)  = d
   |(e&lt;=d) &amp;&amp; (e&lt;=f)  = e
   |otherwise     = f
  
  middle g h i
   | (g &lt;= (max g h i)) &amp;&amp; (g &gt;= (min g h i)) = g
   | (h &lt;= (max g h i)) &amp;&amp; (h &gt;= (min g h i)) = h
   | otherwise                    = i
  
  orderTriple (a,b,c) = ((min a b c),(middle a b c),(max a b c))
  </code></pre>
  
  <p>The error is:</p>
  
  <pre><code>orderList.hs:23:13:
      Couldn't match expected type `[Int -&gt; Int -&gt; Int]'
                  with actual type `(t0, t1, t2)'
      In the pattern: (a, b, c)
  In an equation for `orderTriple':
      orderTriple (a, b, c) = [(min a b c), (middle a b c), (max a b c)]
  </code></pre>