Why is char[][] = {{…}, {…}} not possible if explicitly given a multidimensional array?

后端 未结 5 1833
灰色年华
灰色年华 2020-12-05 18:30

I went through this article. I understand the rules explained but I am wondering what exactly blocks the compiler from accepting the following syntax when defining a constan

5条回答
  •  忘掉有多难
    2020-12-05 18:56

    The rule is that compiler determines only first dimension of the array by the given initializer list. It expects second dimension to be specified explicitly. Period.

提交回复
热议问题