Interview Questions

Is there any sample C# code for simple threading?

C# Interview Questions and Answers


(Continued from previous question...)

89. Is there any sample C# code for simple threading?

Some sample code follows: using System;
using System.Threading;
class ThreadTest
{
public void runme()
{
Console.WriteLine("Runme Called");
}
public static void Main(String[] args)
{
ThreadTest b = new ThreadTest();
Thread t = new Thread(new ThreadStart(b.runme));
t.Start();
}
}

(Continued on next question...)

Other Interview Questions