Lionel Bouton
8/16/2007 11:24:00 AM
Emil Sandin wrote the following on 16.08.2007 13:20 :
> [...]
> Thread.new do
> loop{
> puts "hello"
> sleep 1
> }
> end
>
>
>
> it prints it only one time and then exits.
> Why is that?
>
You don't wait for the Thread to stop to exit your program.