static class Program
    {        /// <summary>
        /// 应用程序的主入口点。
        /// </summary>
        [STAThread]
        static void Main()
        {
           
            List<tcc> tcclist=new List<tcc>();
            for(int i=0;i<10;i++){
                tcclist.Add(new tcc{name="tcc"+i});
                
            }
            
            
            foreach(tcc c in tcclist)
            {
                c.endE+=new tcc.endEvent(delegate()
                {
                    Console.WriteLine(c.name + "------end");
                });
                Thread t = new Thread(delegate()
                {                    Console.WriteLine(c.name+"-----go");
                    
                    c.cfun();                });
                t.Start();
            Thread.Sleep(1000);
            }        }
        
    }    public class tcc
    {
        public delegate void endEvent();
         public event endEvent endE;
        public string name = "";
        public void cfun()
        {
            Thread.Sleep(100);
            endE();
        }
    }