title: Tell the end of a .each loop in ruby
body: <p>If i have a loop such as </p>
  
  <pre><code>users.each do |u|
    #some code
  end
  </code></pre>
  
  <p>Where users is a hash of multiple users.  What's the easiest conditional logic to see if you are on the last user in the users hash and only want to execute specific code for that last user so something like</p>
  
  <pre><code>users.each do |u|
    #code for everyone
    #conditional code for last user
      #code for the last user
    end
  end
  </code></pre>