Quiz on Decision Control Structures in C Programming

Quiz on Decision Control Structures in C Programming

University

14 Qs

quiz-placeholder

Similar activities

NESTED-IF, FOR & WHILE LOOP By handawnz

NESTED-IF, FOR & WHILE LOOP By handawnz

University

12 Qs

placement g2 quiz-1

placement g2 quiz-1

University

15 Qs

Conditional Statements and Loops Quiz

Conditional Statements and Loops Quiz

University

10 Qs

PHP Programming Quiz 2

PHP Programming Quiz 2

University

14 Qs

Session 06: Loop

Session 06: Loop

University

18 Qs

แข่งขันcodingม.ต้น

แข่งขันcodingม.ต้น

12th Grade - University

15 Qs

Mastering Python Control Flow

Mastering Python Control Flow

University

15 Qs

Quiz sobre el ornitorrinco y la programación

Quiz sobre el ornitorrinco y la programación

8th Grade - University

15 Qs

Quiz on Decision Control Structures in C Programming

Quiz on Decision Control Structures in C Programming

Assessment

Quiz

Information Technology (IT)

University

Hard

Created by

<3 M.

FREE Resource

14 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What keyword is used to implement the decision control instruction in C?

switch

if

while

for

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the else statement in an if-else construct?

To execute a statement if the condition is true

To create a loop

To execute a statement if the condition is false

To terminate the program

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the general form of an if statement for multiple statements?

if(condition) statement;

if(condition) { block of statement; }

if { condition } statement;

if(condition) then statement;

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the break statement do in a switch-case structure?

Exits the switch block

Starts a new case

Ends the program

Continues to the next case

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following cannot be tested using a switch statement?

String expressions

Float expressions

Integer expressions

Character expressions

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the default case in a switch statement used for?

To handle all cases

To execute the first case

To handle the case when none match

To terminate the program

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is an if-else ladder?

A series of nested if statements

A single if statement

A switch statement

A loop structure

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?