title: Haskell too many arguments error
body: <p>I am learning Haskell. I am trying to make a function that deletes integers out of a list when met with the parameters of a certain function f. </p>
  
  <pre><code>deleteif :: [Int] -&gt; (Int -&gt; Bool) -&gt; [Int]
  deleteif x f = if x == [] 
                  then [] 
                  else if head x == f 
                         then deleteif((tail x) f)  
                         else [head x] ++ deleteif((tail x) f)
  </code></pre>
  
  <p>I get the following errors :</p>
  
  <ul>
  <li><p>function tail is applied to two arguments</p></li>
  <li><p>'deleteif' is applied to too few arguments</p></li>
  </ul>