using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication8
{
class Program
{
static void Main(string[] args)
{
List<A> test = new List<A>();//集合内对象类型须一致
ArrayList testArrayList = new ArrayList();//集合内对象类型可以多样
Dictionary<string,int> testDictionary = new Dictionary<string, int>();
testDictionary.Add( "k12",12);
testDictionary.Add( "k13",13);
testDictionary.Add( "k123",17);
int x = testDictionary["k12"];
}
}
class A
{
}
}
集合杂记
猜你喜欢
转载自blog.csdn.net/qq_37627370/article/details/83583328
今日推荐
周排行