using System;
class MainClass
{
static void Main()
{
int[][] sample = new int[3][];
sample[0] = new int[] { 1, 2, 3, 4, 5 };
sample[1] = new int[] { 1, 2 };
sample[2] = new int[] { 1, 2, 3 };
Console.WriteLine(sample[0][0] == 1);
Console.WriteLine(sample[0][2] == 3);
Console.WriteLine(sample[0][4] == 5);
Console.WriteLine(sample[1][1] == 2);
Console.WriteLine(sample[2][0] == 1);
Console.WriteLine(sample[2][2] == 3);
}
}
0 コメント:
コメントを投稿