wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

ITC 112 - Topic 3 Quiz

Total questions: 55

Worksheet time: 28mins

Name
Class
Date
1.

The programmer wants to display the result of an equation immediately after getting the inputs.

a)

Sequence

b)

Selection

c)

Repetition

2.

The code executes step-by-step without any conditions or loops.

a)

Sequence

b)

Selection

c)

Repetition

3.

The program calculates the area of a rectangle after reading length and width.

a)

Sequence

b)

Selection

c)

Repetition

4.

The student wrote a code that adds two numbers, then prints the total.

a)

Sequence

b)

Selection

c)

Repetition

5.

A beginner programmer is learning to run statements one after another in the exact order they appear.

a)

Sequence

b)

Selection

c)

Repetition

6.

The programmer wants the program to decide whether a student passes or fails based on an average grade.

a)

Sequence

b)

Selection

c)

Repetition

7.

The code must choose which discount to apply depending on the total purchase amount.

a)

Sequence

b)

Selection

c)

Repetition

8.

The program displays a different message depending on the user’s gender input (M or F).

a)

Sequence

b)

Selection

c)

Repetition

9.

The system needs to determine which day of the week to print based on a user’s choice number (1–7).

a)

Sequence

b)

Selection

c)

Repetition

10.

A programmer needs to check several conditions to pick the best output — for example, which of three numbers is largest.

a)

Sequence

b)

Selection

c)

Repetition

11.

The program asks the user to enter a password until the correct one is typed.

a)

Sequence

b)

Selection

c)

Repetition

12.

The programmer wants to calculate the running total of sales until the user enters “0.”

a)

Sequence

b)

Selection

c)

Repetition

13.

The system prints numbers from 1 to 10 automatically.

a)

Sequence

b)

Selection

c)

Repetition

14.

A programmer wants to make the computer continue showing a menu until the user chooses “Exit.”

a)

Sequence

b)

Selection

c)

Repetition

15.

The code needs to keep checking sensor data until the temperature goes below 30°C.

a)

Sequence

b)

Selection

c)

Repetition

16.

The program should check if a student qualifies for honors; if the average is ≥ 90, display “With Honors.”

a)

One Way Selection

b)

If Else Block

c)

Switch

17.

The programmer wants to execute a statement only when the entered number is positive.

a)

One Way Selection

b)

If Else Block

c)

Switch

18.

The system must display “Access Granted” only when the password is correct.

a)

One Way Selection

b)

If Else Block

c)

Switch

19.

The code needs to add a bonus to salary only if the employee has perfect attendance.

a)

One Way Selection

b)

If Else Block

c)

Switch

20.

The program prints “Low Battery” when the power level drops below 20%.

a)

One Way Selection

b)

If Else Block

c)

Switch

21.

The program decides whether a student passes or fails based on an input grade.

a)

One Way Selection

b)

If Else Block

c)

Switch

22.

The ATM system checks if the withdrawal amount is available: dispense cash if enough, otherwise show “Insufficient Funds.”

a)

One Way Selection

b)

If Else Block

c)

Switch

23.

The code should display “Even Number” when divisible by 2, and “Odd Number” otherwise.

a)

One Way Selection

b)

If Else Block

c)

Switch

24.

The program determines whether the entered temperature means “Hot” or “Cold.”

a)

One Way Selection

b)

If Else Block

c)

Switch

25.

The system must show “Login Successful” for correct credentials and “Invalid Login” for wrong ones.

a)

One Way Selection

b)

If Else Block

c)

Switch

26.

The programmer wants the program to choose among several grade remarks:
90–100 → Excellent, 80–89 → Very Good, 70–79 → Good, Below 70 → Fail.

a)

One Way Selection

b)

If Else Block

c)

Switch

27.

The vending machine should show the selected item based on number (1 for Water, 2 for Juice, 3 for Soda).

a)

One Way Selection

b)

If Else Block

c)

Switch

28.

The traffic-light program must display “Go,” “Ready,” or “Stop” depending on a color input.

a)

One Way Selection

b)

If Else Block

c)

Switch

29.

A menu-driven program offers multiple options: Add, Edit, Delete, Exit. Each option performs a different action.

a)

One Way Selection

b)

If Else Block

c)

Switch

30.

The grading system displays “A,” “B,” “C,” “D,” or “F” depending on the numeric score range.

a)

One Way Selection

b)

If Else Block

c)

Switch

31.

The program should repeatedly ask the user to enter a correct password until it matches the stored one.

a)

While Loop

b)

Do While Loop

c)

For Loop

32.

A sensor keeps checking the room temperature every second until it is above 25 °C.

a)

While Loop

b)

Do While Loop

c)

For Loop

33.

The code continues to read data from a file as long as there are still records remaining.

a)

While Loop

b)

Do While Loop

c)

For Loop

34.

The system must display the menu again and again unless the user has not selected “Exit.”

a)

While Loop

b)

Do While Loop

c)

For Loop

35.

The program computes interest repeatedly until the balance is greater than zero.

a)

While Loop

b)

Do While Loop

c)

For Loop

36.

The program must execute a calculation at least once, even if the condition becomes false afterwards.

a)

While Loop

b)

Do While Loop

c)

For Loop

37.

The system asks, “Do you want to continue?” and repeats the process based on the user’s response.

a)

While Loop

b)

Do While Loop

c)

For Loop

38.

The code displays a set of quiz questions, then asks at the end if the user wants to try again.

a)

While Loop

b)

Do While Loop

c)

For Loop

39.

A simple guessing game runs once and keeps looping after each wrong answer, until the correct guess is entered.

a)

While Loop

b)

Do While Loop

c)

For Loop

40.

The program shows the transaction summary first, then asks if the user wants another transaction.

a)

While Loop

b)

Do While Loop

c)

For Loop

41.

The programmer wants to print numbers 1 to 100 automatically without user input.

a)

While Loop

b)

Do While Loop

c)

For Loop

42.

The code should add the first 10 natural numbers and display their sum.

a)

While Loop

b)

Do While Loop

c)

For Loop

43.

The program must display the multiplication table of 5 (from 1 to 10).

a)

While Loop

b)

Do While Loop

c)

For Loop

44.

A loop executes a fixed number of times to compute grades for 30 students in a class.

a)

While Loop

b)

Do While Loop

c)

For Loop

45.

The system repeats a set of tasks exactly 5 times before stopping.

a)

While Loop

b)

Do While Loop

c)

For Loop

46.

The program checks if the user’s entered PIN is exactly the same as the stored PIN.

a)

==

b)

!=

c)

>

d)

<

e)

<=

47.

The system must display “Invalid input” when the entered age is not equal to a required value.

a)

==

b)

!=

c)

>

d)

<

e)

<=

48.

The code needs to determine if a student’s grade is higher than 90 to qualify for honors.

a)

==

b)

!=

c)

>

d)

<

e)

<=

49.

A loop continues while the entered number is not more than 100.

a)

==

b)

!=

c)

>

d)

<

e)

<=

50.

The program should only allow access if the number of attempts is smaller or the same as 3.

a)

==

b)

!=

c)

>

d)

<

e)

<=

51.

The program grants login access only if the username and password are both correct.

a)

&&

b)

||

c)

!

52.

The system displays “Discount Applied” when the user is a member or has a coupon.

a)

&&

b)

||

c)

!

53.

The machine continues operation only if the power is ON and the emergency stop is OFF.

a)

&&

b)

||

c)

!

54.

The program displays “Access Denied” when the input password is not equal to the stored password.

a)

&&

b)

||

c)

!

55.

The vending machine dispenses a product if payment is complete or a promo code is entered.

a)

&&

b)

||

c)

!