FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
jruby/samples/thread.rb at test-latest_java8 · MSNexploder/jruby · GitHub
MSNexploder
/
jruby
Public
forked from
jruby/jruby
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
jruby
/
samples
/
thread.rb
Copy path
More file actions
More file actions
Latest commit
History
History
History
5 lines (5 loc) · 208 Bytes
Breadcrumbs
jruby
/
samples
/
thread.rb
Copy path
File metadata and controls
5 lines (5 loc) · 208 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
x
=
Thread
.
new
{
sleep
0.1
;
print
"x"
;
print
"y"
;
print
"z"
}
a
=
Thread
.
new
{
print
"a"
;
print
"b"
;
sleep
0.2
;
print
"c"
}
x
.
join
# Let the threads finish before
a
.
join
# main thread exits...
puts
# newline
Back
|
FazBrowse Home
|
New Git URL