123456789101112131415161718
use strict;use threads; my $th_inc = threads->new( \&kind );sub kind { my $var = 0; while(1) { $var++; fertig($var); last if $var == 10; } return 0;}sub fertig { # hier steht nichts drin}