title: stack of blocks answers true if they are on top of each other
body: <p>Define a stack of  blocks as on the picture:
  Given the relations</p>
  
  <p>on(b,a). 
  on(c,b).
  on(d,c).</p>
  
  <p>Define a Prolog predicate above(Block2,Block1) that is true if Block2 is above Block1.</p>
  
  <p>So I have:</p>
  
  <pre><code>on(b,a).
  on(c,b).
  on(d,c).
  above(Block2,Block1):- on(X,Y).
  </code></pre>
  
  <p>But this code appears to be broken it answers true either way I need it to answer false if they are not on top of each other.</p>