Complete the code to declare an array of 5 integers.
int numbers[[1]];The number inside the square brackets specifies the size of the array. Here, 5 means the array can hold 5 integers.
Complete the code to access the third element of the array.
int third = numbers[[1]];Array indexing in C starts at 0, so the third element is at index 2.
Fix the error in the code to initialize an array with values 1 to 5.
int numbers[5] = {1, 2, 3, 4, [1];
The array should be initialized with values 1 through 5, so the last value must be 5.
Fill both blanks to create an array of 4 floats and assign 3.14 to the first element.
float [1][[2]]; [1][0] = 3.14;
The array is named 'values' and has size 4. Then we assign 3.14 to the first element.
Fill all three blanks to declare an integer array named 'scores' of size 3 and assign 100 to the last element.
int [1][[2]]; [1][[3]] = 100;
The array is named 'scores' with size 3. The last element is at index 2 (since indexing starts at 0), so we assign 100 there.