3
Reply

How i can initialize a three Dimensional array?

Amirhossein Ahmadi

Amirhossein Ahmadi

Mar 2 2017 8:31 AM
220
Hi there, i can initialize a two dimensional array:
  1. int[,] myDimensional2 = new int[2, 3] { { 10, 20, 30 }, { 40, 50, 60} };  
but i don't know how i can initialize a three, four,... dimensional arrays? :(
please initialize this array and give me the code, thank you so much :)
  1. int[,,] threeDimensional = new int[2, 2, 3];  

Answers (3)