Skip to content

Instantly share code, notes, and snippets.

@yorickpeterse
Created October 2, 2014 11:25
Show Gist options
  • Save yorickpeterse/746c7b081f9d7e40d987 to your computer and use it in GitHub Desktop.
Save yorickpeterse/746c7b081f9d7e40d987 to your computer and use it in GitHub Desktop.
numbers = [10, 20, 30]
threads = []
numbers.each do |number|
threads << Thread.new { puts number }
end
threads.each(&:join)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment