<分区>
Possible Duplicate:
C#: Difference between ‘ += anEvent’ and ‘ += new EventHandler(anEvent)’
让我们有这个委托(delegate):
delegate int Process (int x ,int y) ;
和这个方法:
int Add (int x , int y)
{
return x+y ;
}
我的问题:
有什么区别:
Process MyProcess = Add ;
和:
Process MyProcess = new Process (Add) ;