title: Finding if two numbers have the same digit and then remove them from in the original number in Haskell
body: <p>I am doing <a href="http://projecteuler.net/index.php?section=problems&amp;id=33" rel="nofollow noreferrer">project euler question 33</a> and have divised a refactor to solve it but I can't think of how to remove the digit if it is the same across both <code>x</code> and <code>y</code>.
  I got this far:</p>
  
  <pre><code>import Ratio
  import List
  p33 =  [ (x%y) | y &lt;- [10..99] , x &lt;- [10..y], (x `rem` 10) /= 0 , (y `rem` 10) /= 0 , x /= y , (length $ nub $ concat $ map decToList [x,y]) == 3 , [numerator(x%y),denominator(x%y)] == WHAT GOES HERE? ]
  </code></pre>
  
  <p>The cancelling of 0's is not allowed.
  What it should do is:</p>
  
  <pre><code>49/98 {cancel the 9's}
  </code></pre>
  
  <p>to get:</p>
  
  <p>4/8 as the result. But I can't think of how to remove the common digits from each number.</p>