![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
c#
木木娅.
游戏图形程序员
展开
-
c#中委托
委托声明:Delegate作用:传递方法(将方法以变量的形式传递,并且以方法的形式执行)注意:委托的参数和我们使用的参数必须一致using System;namespace Entrust{ //定义委托的关键字delegate public delegate void SayHi(string str); class Program { static void Main(string[] args) {原创 2021-07-20 10:41:24 · 199 阅读 · 0 评论 -
c#-Lambda 表达式
首先看正常情况我们函数的调用和使用using System;namespace Test{ class Program { static void Main(string[] args) { int a = 100; int b = 150; int nums = TextAdd(a, b); Console.WriteLine(nums);原创 2021-08-07 10:20:57 · 59 阅读 · 0 评论