C Programming Quiz(session2)

C Programming Quiz(session2)

10th Grade

21 Qs

quiz-placeholder

Similar activities

Bài tập tin 8 tiết 38

Bài tập tin 8 tiết 38

10th Grade

20 Qs

UTS KOMJAR

UTS KOMJAR

10th Grade

20 Qs

Asas JavaScript

Asas JavaScript

1st Grade - University

18 Qs

UH2 - Jaringan Komputer

UH2 - Jaringan Komputer

10th Grade

20 Qs

ULANGAN HARIAN KONSEP DASAR JARINGAN KOMPUTER

ULANGAN HARIAN KONSEP DASAR JARINGAN KOMPUTER

10th Grade

17 Qs

12AIT - All About W3C <3

12AIT - All About W3C <3

10th Grade - University

18 Qs

Advantages and Disadvantages of Collecting Data

Advantages and Disadvantages of Collecting Data

10th Grade

20 Qs

History of Package Design

History of Package Design

9th - 12th Grade

20 Qs

C Programming Quiz(session2)

C Programming Quiz(session2)

Assessment

Quiz

Computers

10th Grade

Practice Problem

Medium

Created by

Sumithra pm

Used 2+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

21 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following is the correct syntax for the ternary operator in C?

if ? else :

condition ? true_value : false_value;

? condition : true_value;

if (condition) ? true : false;

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

What is the output of the following code? int a = 10; if (a > 5) printf("A"); else printf("B");

A

B

Nothing

Error

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which loop guarantees at least one execution of the loop body?

for

while

do...while

if

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which control statement is best suited for multiple constant-value selections?

if

else if

switch

while

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

What will the following code print? int i; for (i = 1; i 0) ? printf("Positive") : printf("Negative");

Positive

Negative

Error

Nothing

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following is not a valid keyword in C for control statements?

if

switch

select

else

7.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

The default keyword is used in which control structure?

if

else if

switch

while

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?