title: Stuck with Prolog
body: <p>I just started learning Prolog. One of the exercise wants me to write backwards/2, a predicate that is true when the second list argument is the reverse of the first list argument. And I have to use a paste predicate to write backwards.</p>
  
  <pre><code>paste([], L, L).
  paste([X|L1], L2, [X|L3]) :- paste(L1,L2,L3).
  </code></pre>
  
  <p>I worked on it for hours but still haven't gotten the answer.</p>
  
  <p>Here's what I have:</p>
  
  <pre><code>backwards([H|T], Lrev) :- paste([X|T], X, Lrev).
  backwards([],[]).
  </code></pre>