title: Can you assign two variables simultaneously in R?
body: <p>I am using the example of calculating the length of the arc around a circle and the area under the arc around a circle based on the radius of the circle (r) and the angle of the the arc(theta).  The area and the length are both based on r and theta, and you can calculate them simultaneously in python.</p>
  
  <p>In python, I can assign two values at the same time by doing this.</p>
  
  <pre><code>    from math import pi
      def circle_set(r, theta):
          return theta * r, .5*theta*r*r
  
      arc_len, arc_area = circle_set(1, .5*pi) 
  </code></pre>
  
  <p>Implementing the same structure in R gives me this.</p>
  
  <pre><code>    circle_set &lt;- function(r, theta){
          return(theta * r, .5 * theta * r *r)
          }
  
      arc_len, arc_area &lt;- circle_set(1, .5*3.14)
  </code></pre>
  
  <p>But returns this error.</p>
  
  <blockquote>
    <p>arc_len, arc_area &lt;- circle_set(1, .5*3.14)</p>
    
    <p>Error: unexpected ',' in "arc_len,"</p>
  </blockquote>
  
  <p>Is there a way to use the same structure in R?</p>