title: Haskell, creating a binary search tree from a list
body: <p>Can someone tell me why this code isn't producing what I want. </p>
  
  <pre><code>data BST = MakeNode BST String BST
             | Empty
  
  
  add :: String -&gt; BST -&gt; BST
  add new Empty = (MakeNode Empty new Empty)
  add string tree@(MakeNode left value right)
      | string &gt; value = MakeNode left value (add string right)
      | string &lt; value = MakeNode (add string left) value right
      | otherwise = tree
  </code></pre>
  
  <p>output </p>
  
  <pre><code> "John"
      "Doug"
          "Charlie"
  </code></pre>
  
  <p>"Alice"</p>
  
  <pre><code>listToBST :: [String] -&gt; BST
  listToBST = foldr add Empty
  </code></pre>