键值为string类型,可以存储数据
列表可以存储数据
Dictionary<string, List<string>> CurrentValue = new Dictionary<string, List<string>>();
private void button1_Click(object sender, EventArgs e)
{
List<string> list; //定义列表
for (int i = 0; i < 5; i++)
{
list = new List<string>();
list.Add(i.ToString());
list.Add(i.ToString());
list.Add(i.ToString());
CurrentValue[i+"ge"] = list;
}
for (int i = 0; i < 3; i++)
{
string a=CurrentValue[0 + "ge"][i];
string b=CurrentValue[0 + "ge"][i];
string c=CurrentValue[0 + "ge"][i];
}
}