2 using System
.Threading
;
5 static long fib (long n
) {
9 return fib (n
- 1) + fib (n
- 2);
13 for (long i
= 0; i
< 30; ++i
)
14 Console
.WriteLine (fib (i
).ToString ());
15 Console
.WriteLine ("exiting");
16 System
.Environment
.Exit (0);
21 public static Thread
newThread () {
22 FibThread ft
= new FibThread ();
23 return new Thread (new ThreadStart (ft
.work
));
27 Thread t
= newThread ();
29 Console
.WriteLine ("started");