Loops
Arrays
Strings & Characters
Control Statements
Program Output
100

This loop is best used when the number of repetitions is unknown.

while loop

100

The index number where arrays start in C.

0

100

This data type stores a single character.

char

100

This statement immediately exits a loop.

break

100

int i = 1;
while(i <= 3){
    printf("%d ", i);
    i++;
}

1 2 3

200

This loop is commonly used when counting from 1 to 10.

for loop

200

The correct declaration for an integer array with 5 elements.

int arr[5];

200

In C, a string is stored as this type of structure.

character array

200

This statement skips the remaining code in the current iteration.

continue

200

for(int i = 5; i > 0; i--){
    printf("%d ", i);
}

5 4 3 2 1

300

This loop guarantees the code will run at least once.

do-while loop

300

This type of structure stores multiple values of the same data type.

array

300

This character marks the end of a string.

\0 (null character)

300

This statement is often used to stop input if a condition is met.

break

300

for(int i = 1; i <= 5; i++){
    if(i == 3)
        break;
    printf("%d ", i);
}

1 2

400

This part of a loop increases or decreases the counter value.

increment/decrement (i++ or i--)

400

The index of the last element in int a[10];

9

400

This function safely reads a string including spaces.

fgets()

400

When this statement executes, the loop jumps directly to the next iteration.

continue

400

for(int i = 1; i <= 5; i++){
    if(i == 3)
        continue;
    printf("%d ", i);
}

1 2 4 5

500

This happens if the condition of a while loop is false at the beginning.

the loop does not run

500

This loop is most commonly used to input values into an array.

for loop

500

This is NOT a valid string declaration in C.

string name;

500

These two statements are commonly used for controlling loops.

break and continue

500

int arr[3] = {10,20,30};
printf("%d", arr[1]);

20