C Programing Quiz

C Programing Quiz

University

15 Qs

quiz-placeholder

Similar activities

Components of GIS & Levels/Scales

Components of GIS & Levels/Scales

University

12 Qs

多媒體概論(2)

多媒體概論(2)

University - Professional Development

20 Qs

Round 2 for Preplacement Bootcamp

Round 2 for Preplacement Bootcamp

University

15 Qs

Web Designing Quiz-2

Web Designing Quiz-2

University

10 Qs

Kiểm tra học kỳ 1 lớp 2

Kiểm tra học kỳ 1 lớp 2

2nd Grade - University

10 Qs

Trắc nghiệm excel - 1

Trắc nghiệm excel - 1

KG - University

20 Qs

PSSI Chp 1 dan 2

PSSI Chp 1 dan 2

University

12 Qs

Bài tập lớp 4_tuần 5

Bài tập lớp 4_tuần 5

University

10 Qs

C Programing Quiz

C Programing Quiz

Assessment

Quiz

Computers

University

Practice Problem

Easy

Created by

Muntazim Alam

Used 1+ times

FREE Resource

AI

Enhance your content in a minute

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

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which loop guarantees that the loop body will be executed at least once?

  • A) for

  • B) while

  • C) do-while

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code?

int arr[5] = {1, 2, 3, 4, 5}; printf("%d", arr[3]);

  • A) 3

  • B) 4

  • C) 5

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following correctly defines a function with no return value and no parameters?

  • A) void func() {}

  • B) func(void) {}

  • C) int func() {}

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the following code snippet print?

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

  • A) 0 1 2 3 4

  • B) 1 2 3 4 5

  • C) 0 1 2 3 4 5

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct syntax to access the last element of an array arr with 10 elements?

  • A) arr[9]

  • B) arr[10]

  • C) arr[8]

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code?

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

  • A) 6

  • B) 5

  • C) 10

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following statements is true about functions in C?

  • A) Functions cannot return arrays.

  • B) Functions can only have one parameter.

  • C) Functions cannot call other functions.

Create a free account and access millions of resources

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?