Add elements to existing list in Scheme
<p>Hi i am learning Scheme new.I have question.Lets think I have defined a function which it adds element to list if it is empty.If there is an element in list and new element is added as second to list and goes like this.For example</p>

<pre><code>&gt;(add a) ; here list is empty
'(a) 
&gt;(add b) ; here a is in the list
'(a b)  
&gt;(add c) ; here a and b is in the list
(a b c)
</code></pre>

<p>List is updated like this.How can I write a function like this.I add elements to empty list each time with my code.I mean it is like that with mine.</p>

<pre><code>&gt;(add a)
'(a)
&gt;(add b)
'(b)
&gt;(add c)
'(c)
</code></pre>

<p>How can I write the proper code for this purpose ? 
here is my code </p>

<pre><code>#lang racket
 (define addToList
  (lambda (a b)
    (cond ((null? a) b)
          ((null? b) a)
          ((cons (car a) (addToList (cdr a) b))))))
 (addToList '(1 2 3) '())
</code></pre>