请高手帮我解答下这C#代码每行的意思!感激不尽!

来源:百度知道 编辑:UC知道 时间:2024/09/18 05:15:53
using System;
using System.Threading;
class Demo
{
public void temp()

{
Console.WriteLine(" this is a threading!");

}
public static void Main()
{

Demo val=new Demo();
Thread x = new Thread(new ThreadStart(val.temp));
x.Start();
}
}

using System;
using System.Threading;
class Demo 一个Demo类
{
public void temp() 一个公开没有返回值的temp方法

{
Console.WriteLine(" this is a threading!"); 输出““this is a threading!"); ”

}
public static void Main() 公开的静态的Main方法
{

Demo val=new Demo(); 实例化Demo
Thread x = new Thread(new ThreadStart(val.temp)); 线程x=
x.Start();
}
}