'Illegal start of expression' 使用二维数组时出错

'Illegal start of expression' errors when using 2D array

当我像这样初始化二维数组时:

private double[][] rates = {{1.0,361.900,0.65963,1512.00,1740.00,2446.00,2417.00,133.547,2610.00,2855.00,13758.0,4101.00,4290.00,4710.00,6.46000,7112.50,8115.00,12588.0,27294.0,20742.5,21377.5,824.966,0.00124},
    {0.00276,1.0,0.00182,4.17795,4.80796,6.75877,6.67864,0.36902,7.21194,7.88892,38.0160,11.3318,11.8541,13.0146,0.01785,19.6532,22.4233,34.7832,75.4186,57.3155,59.0701,2.27954,0.00001},
    {1.51600,548.640,1.0,2292.19,2637.84,3708.13,3664.17,202.458,3956.76,4328.18,20857.1,6217.11,6503.64,7140.36,9.79336,10782.5,12302.3,19083.4,41377.7,31445.6,32408.2,1250.64,0.00189},
    {0.00066,0.23935,0.00044,1.0,1.15079,1.61772,1.59854,0.08833,1.72619,1.88823,9.09921,2.71230,2.83730,3.11508,0.00427,4.70403,5.36706,8.32543,18.0515,13.7185,14.1385,0.54561,0.00001},
    {0.00057,0.20799,0.00038,0.86897,1.0,1.40575,1.38908,0.07675,1.50000,1.64080,7.90690,2.35690,2.46552,2.70690,0.00371,4.08764,4.66379,7.23451,15.6862,11.9209,12.2859,0.47412,0.00001},
    {0.00041,0.14796,0.00027,0.61815,0.71137,1.0,0.98814,0.05460,1.06705,1.16721,5.62469,1.67661,1.75388,1.92559,0.00264,2.90781,3.31766,5.14638,11.1586,8.48017,8.73978,0.33727,0.000001},
    {0.00041,0.14973,0.00027,0.62557,0.71990,1.01200,1.0,0.05525,1.07985,1.18122,5.69218,1.69673,1.77493,1.94870,0.00267,2.94270,3.35747,5.20813,11.2925,8.58192,8.84464,0.34132,0.00001},
    {0.00749,2.70989,0.00494,11.3217,13.0290,18.3155,18.0983,1.0,19.5435,21.3781,103.019,30.7081,32.1233,35.2682,0.04837,53.2580,60.7647,94.2587,204.376,155.318,160.073,6.17732,0.00001},
    {0.00038,0.13866,0.00025,0.57931,0.66667,0.93716,0.92605,0.05117,1.0,1.09387,5.27126,1.57126,1.64368,1.80460,0.00248,2.72510,3.10920,4.82301,10.4574,7.94732,8.19061,0.31608,0.00001},
    {0.00035,0.12676,0.00023,0.52960,0.60946,0.85674,0.84658,0.04678,0.91419,1.0,4.81891,1.43643,1.50263,1.64974,0.00226,2.49124,2.84238,4.40912,9.56007,7.26532,7.48774,0.28896,0.00001},
    {0.00007,0.02630,0.00005,0.10990,0.12647,0.17779,0.17568,0.00971,0.18971,0.20752,1.0,0.29808,0.31182,0.34235,0.00047,0.51697,0.58984,0.91496,1.98386,1.50767,1.55382,0.05996,0.00001},
    {0.00024,0.08825,0.00016,0.36869,0.42429,0.59644,0.58937,0.03256,0.63643,0.69617,3.35479,1.0,1.04609,1.14850,0.00158,1.73433,1.97879,3.06951,6.65545,5.05791,5.21275,0.20116,0.00001},
    {0.00023,0.08436,0.00015,0.35245,0.40559,0.57016,0.56340,0.03113,0.60839,0.66550,3.20699,0.95594,1.0,1.09790,0.00151,1.65793,1.89161,2.93428,6.36224,4.83508,4.98310,0.19230,0.00001},
    {0.00021,0.07684,0.00014,0.32102,0.36943,0.51932,0.51316,0.02835,0.55414,0.60616,2.92102,0.87070,0.91083,1.0,0.00137,1.51008,1.72293,2.67262,5.79490,4.40393,4.53875,0.17515,0.00001},
    {0.15480,56.0216,0.10211,234.055,269.349,378.637,374.148,20.6730,404.024,441.950,2129.72,634.829,664.086,729.102,1.0,1101.00,1256.19,1948.61,4225.07,3210.91,3309.21,127.703,0.00019},
    {0.00014,0.05088,0.00009,0.21258,0.24464,0.34390,0.33982,0.01878,0.36696,0.40141,1.93434,0.57659,0.60316,0.66221,0.00091,1.0,1.14095,1.76985,3.83747,2.91634,3.00562,0.11599,0.00001},
    {0.00012,0.04460,0.00008,0.18632,0.21442,0.30142,0.29784,0.01646,0.32163,0.35182,1.69538,0.50536,0.52865,0.58041,0.00080,0.87646,1.0,1.55121,3.36340,2.55607,0.00765,0.10166,0.00001},
    {0.00008,0.02875,0.00005,0.12011,0.13823,0.19431,0.19201,0.01061,0.20734,0.22680,1.09294,0.32579,0.34080,0.37416,0.00051,0.56502,0.64466,1.0,2.16825,1.64779,1.69824,0.06554,0.00001},
    {0.00004,0.01326,0.00002,0.05540,0.06375,0.08962,0.08855,0.00489,0.09563,0.10460,0.50407,0.15025,0.15718,0.17257,0.00024,0.26059,0.29732,0.46120,1.0,0.75997,0.78323,0.03023,0.00001},
    {0.00005,0.01745,0.00003,0.07289,0.08389,0.11792,0.11652,0.00644,0.12583,0.13764,0.66328,0.19771,0.20682,0.22707,0.00031,0.34290,0.39123,0.60687,1.31585,1.0,1.03061,0.03977,0.00001},
    {0.00005,0.01693,0.00003,0.07073,0.08139,0.11442,0.11306,0.00625,0.12209,0.13355,0.64357,0.19184,0.20068,0.22033,0.00030,0.33271,0.37960,0.58885,1.27676,0.97030,1.0,0.03859,0.00001},
    {0.00121,0.43868,0.00080,1.83280,2.10918,2.96497,2.92981,0.16188,3.16376,3.46075,16.6770,4.97111,5.20021,5.70932,0.00783,8.62156,9.83676,15.2588,33.0849,25.1434,25.9131,1.0,0.00001},
    {803.500,290786.65000,530.013,1214892.00000,1398090.00000,1965361.00000,1942059.50000,107305.64632,2097135.00000,2293992.50000,11054553.00002,3295153.50001,3447015.00001,3784485.00001,5190.61,5714893.75001,6520402.50001,10114498.1750221930729.00003,16666598.75003,17176821.25003,662860.81985,1.0}};

我遇到很多 Illegal start of expression<identifier> expected';' expected 错误。这让我相信我的一些花括号不合适,但我找不到它们。

有人可以告诉我这些错放的括号在哪里,或者是否有更好的方法来声明这样的数组?

这不是双人。

10114498.1750221930729.00003

我不确定你想要什么,但那个号码是行不通的。对小数点后第二位做点什么。

幸运的是,这种异常情况仅此一次;删除它,一切都会正常编译。