title: Relatively prime numbers from a list
body: <p>In racket how can I create a procedure, using <code>filter</code> and <code>gcd</code>, which does the following:</p>
  
  <p><code>(list-of-numbers) number = &gt; (list)</code> </p>
  
  <p>Where the resulting list includes the numbers from the list that are relatively prime to the single one? </p>
  
  <p>EDIT:
  So far I've come up with  the following code:</p>
  
  <pre><code>(define (coprime? list-of-num n)
   (cond 
    [(empty? list-of-num) empty]
    [else
     (filter (lambda (num)
             (= (gcd (first list-of-num) n) 1)) num))]))
  </code></pre>
  
  <p>But I'm completely lost and realize that it's kind of a mess. My general idea is to make a boolean function that returns #t whenever <code>(gcd number-from-list number)</code> equals one and then the procedure filters every number from the list that results in #t.</p>