
Butula TVC CICT II Quiz on Control Structures Quiz
Authored by Andrew Wakoli
Other
University
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
What is the primary purpose of control structures in programming?
To execute statements in a random order
To enable decision making and repetition
To store data temporarily
To compile the program
2.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Which of the following is NOT a type of control structure in C?
Function structures
Repetition structures
Selection structures
Sequence structures
3.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
What does the 'if' statement do in a program?
Terminates the program
Repeats a block of code multiple times
Executes a block of code only if a condition is true
Executes a block of code unconditionally
4.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
In a switch statement, what happens when a 'break' statement is encountered?
The switch statement is exited
The program continues to the next line of code
The flow of control jumps to the next case
The program terminates immediately
5.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Which loop structure guarantees that the loop body will execute at least once?
For loop
Do...while loop
Nested loop
While loop
6.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
What is the purpose of the 'continue' statement in a loop?
To restart the loop from the beginning
To exit the loop immediately
To terminate the program
To skip the current iteration and continue with the next
7.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Which of the following is a characteristic of a nested if statement?
It cannot be used with else statements
It must always return a value
It can contain another if statement inside it
It can only contain one condition
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?