title: What order are method arguments evaluated in Ruby?
body: <p>Up until <a href="https://stackoverflow.com/a/36206391/1241782">my attempt</a> to answer <a href="https://stackoverflow.com/q/36204276/1241782">this question</a> I had always assumed arguments were evaluated from left to right the way we type them. For example we have some method:</p>
  
  <pre><code>def foo(a,b,c)
  </code></pre>
  
  <p>Is there a way to monitor variable definitions and values in a Ruby program as time passes? If you call <code>foo 0,1,2</code> how can you prove that variables assigned in the following order?</p>
  
  <p>time 0: <code>a = 0</code></p>
  
  <p>time 1: <code>b = 1</code></p>
  
  <p>time 2: <code>c = 2</code></p>
  
  <p>I realize my example is trivial because I have the same type of argument for <code>a, b, c</code> but it potentially gets muddied up when you introduce default arguments, keyword arguments, and array arguments. If no one knows the answer I would appreciate suggestions on how to determine the answer.</p>
  
  <p>Basically the Ruby equivalent of <a href="https://stackoverflow.com/questions/12749246/how-to-prove-that-parameter-evaluation-is-left-to-right-in-python">this</a>.</p>