title: Haskell IO with Numbers
body: <p>Can anyone help with this exersise?</p>
  
  <blockquote>
    <p>Write a program which asks the user
    for the base and height of a right
    angled triangle, calculates its area
    and prints it to the screen. The
    interaction should look something
    like:</p>
  </blockquote>
  
  <pre><code>The base?
  3.3
  The height?
  5.4
  The area of that triangle is 8.91
  </code></pre>
  
  <p>Solved with:</p>
  
  <pre><code>getTriArea :: IO Float
  getTriArea = do
   putStr "The base? "
   base &lt;- getLine
   putStr "The height? "
   height &lt;- getLine
   let ar = ( (read base :: Float) * (read height :: Float) )/ 2
   return ar
  
  main = do 
   result &lt;- getTriArea
   putStr $ "The area of that triangle is " ++ show result
  </code></pre>