Count occurrences of an element in a list
Since your type a is required to be an Ord you can access Eq functions. This makes counting occurrences a bit simpler, because you can just filter and count the matching elements:

numTimesFound :: Ord a =&gt; a -&gt; [a] -&gt; Integer
numTimesFound _ [] = 0
numTimesFound x list = sum $ map (\a -&gt; 1) $ filter (== x) list


Of course we don't need to stop there. We can use function composition and length to  write the last line as:

numTimesFound x xs = (length . filter (== x)) xs


In addition to that 200_success raises an interesting point in the comments:


  Actually, there is no reason to require Ord a, when Eq a will do