我已经完成了1d数组并且没有问题,但是我在这里使用2d数组做错了什么? 不知道我哪里出错了,一定是格式化但是看不到树林里的树林!
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Test_Matrix_Declared {
class Program {
static void Main(string[] args) {
string[, ] TestLoads = new string[16, 8];
//Enable, RQuies, RSample, RWriteTx, RDepass, RDischarge, DischargeDate, Discharge Time
{
{
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "383", "1180", "2009-04-03", "16:32:00"
}, {
"1", "475000", "7560", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "475000", "7560", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}, {
"1", "232000", "3770", "100000000", "191", "1180", "2009-04-03", "16:32:00"
}
};
}
}
}
答案 0 :(得分:0)
从
末尾删除分号string[,] TestLoads = new string[16,8];