C#
文章平均质量分 80
姓鲍菇
这个作者很懒,什么都没留下…
展开
-
C# 合并两个int数组 合并后根据大小排序 并输出
static void Main(string[] args) { int[] a = new int[] { 1, 3, 4, 8,30,10 }; int[] b = new int[] { 2, 5, 6, 9, 22,7,11}; //合并数组 int[] temp = new原创 2013-11-29 12:05:10 · 1671 阅读 · 0 评论 -
有关数组 & 动态数组,输出数组中最长字符以及最短字符,若最长最短不止一个,都输出
1、初始化时设置他的数组大小 string[] myarr = new string[2]; myarr[0] = "1"; myarr[1]="第二个值";2、初始化时设置他的数组大小并赋值 string[] myarr = new string[]{"1","2"};3、可以动态改变数组大小的数组 List listArr = new List(); listArr.add(原创 2013-11-29 17:20:11 · 657 阅读 · 0 评论 -
LINQ 常用查询
什么是LINQ? LINQ优点是什么? 1、可以对多种数据源和对象进行查询,如数据库、数据集、xml文档甚至是数组,这在传统的查询语句中是很难实现的。 2、和sql查询规则很相似,容易上手。 说明: LINQ的全称:Language-Intergrated Query 命名空间:System.Linq; Linq是.NET Framework3.5中出现的技术,所以在新建项目的原创 2013-12-02 17:27:55 · 1415 阅读 · 0 评论