'CFG for multidimensional array

What is the right CFG production rule for multidimensional array like array = new int[1][2][3]? it should capture the size of arrays too.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source