title: What does symdiff does (in haskell)
body: <p>I am supposed to fill in something for <code>undefined</code> to get the program compiled and test it. I don't really know what symdiff here is supposed to do, so I don't know what I can fill in for <code>undefined</code>. Can someone give me a hint, what I can insert into <code>undefined</code>?</p>
  
  <p>By the way, when I want to compile the code with ghci 7.6.3 I get an error: 
  <code>Could not find module 'Test.SmallCheck.Series'</code> how can I fix that?</p>
  
  <p>Here is the code:</p>
  
  <pre><code>{-# language FlexibleInstances #-}
  {-# language MultiParamTypeClasses #-}
  {-# language NoMonomorphismRestriction #-}
  
  module Blueprint where
  
  import Test.SmallCheck
  import Test.SmallCheck.Series
  
  data N = Z | S N deriving (Show , Eq)
  
  symdiff :: N -&gt; N -&gt; N
  symdiff x y = undefined
  
  
  
  -- for testing in ghci:  smallCheck 10 spec1
  
  
  spec1 = \ (x,y) -&gt; symdiff x y == symdiff y x
  spec2 = \ (x,y) -&gt; symdiff x (plus x y) == y
  
  
  plus :: N -&gt; N -&gt; N
  plus x y = case x of
      Z -&gt; y
      S x' -&gt; S (plus x' y)
  
  test :: Bool
  test = and
     [ null $ failures 10 1000 $ spec1
     , null $ failures 10 1000 $ spec2   
     ]
  
  instance Monad m =&gt; Serial m N where series = cons0 Z \/ cons1 S
  
  -- | first f failures from t testcases for property p
  failures f t p = take f
                 $ filter ( \ x -&gt; not $ p x ) 
                 $ take t
                 $ do d &lt;- [ 0 .. ] ; list d series
  </code></pre>
  
  <p>thanks, that helped a lot! what about this: </p>
  
  <pre><code>symdiff :: N -&gt; N -&gt; N
  symdiff x y = case x of
      Z -&gt; y
      S x' -&gt; case y of
          Z -&gt; x
          S y' -&gt; ???
  </code></pre>
  
  <p>Are these lines correct (except the line with ???, I am thinking about it at already)</p>
  
  <p>This works for the last line: 
  <code>S y' -&gt; symdiff x' y'</code></p>