// Create a delegate instance delegate void Del(int x); // Instantiate the delegate using an anonymous method Del d = delegate(int k) { /* ... */ }; 使用匿名方法,不必创建单独的方法,因此减少了实例化委托所需的编码系统开销。