in C code the following statement initializes the array int

in C code, the following statement initializes the array, int nums[2][3] = {{ 22, 44}, {66, 97}, {98,99}};

True or False?

Solution

Answer: False

int nums[2][3] = {{ 22, 44}, {66, 97}, {98,99}}; this statment will not initializes the array becuase of to many initializers .

We mentioned in array like 2 rows and 3 colums but we assigned values like 3 rows and 2 columns becuase of that compiler will not allow to create this array with initiaizes.

in C code, the following statement initializes the array, int nums[2][3] = {{ 22, 44}, {66, 97}, {98,99}}; True or False?SolutionAnswer: False int nums[2][3] =

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site