This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

数组初始化问题

我在main函数前面定义了一个全局数组q[100],在线仿真发现这个数组初始值不是0,请问这是怎么回事呢,难道要一个个的赋0吗,写成q[100]={0};也是只有第一个数为0,求解答?