C Programming Coding Assessment

C Programming Coding Assessment

1st Grade

13 Qs

quiz-placeholder

Similar activities

ฟังก์ชั่น

ฟังก์ชั่น

1st Grade - Professional Development

10 Qs

Data Structure and Algorithm

Data Structure and Algorithm

1st - 3rd Grade

15 Qs

Basic of C

Basic of C

1st - 3rd Grade

10 Qs

C++ test

C++ test

1st - 10th Grade

10 Qs

UAS Logika dan Algoritma Pemrograman

UAS Logika dan Algoritma Pemrograman

1st Grade - University

15 Qs

Programação de Computadores - Aula - 7

Programação de Computadores - Aula - 7

1st - 3rd Grade

10 Qs

Pseudo Code

Pseudo Code

1st - 3rd Grade

10 Qs

basic Arrays,Strings,Looping,pointers in c program

basic Arrays,Strings,Looping,pointers in c program

1st Grade

16 Qs

C Programming Coding Assessment

C Programming Coding Assessment

Assessment

Quiz

Computers

1st Grade

Hard

Created by

Jeyam Jacqueline S

FREE Resource

13 questions

Show all answers

1.

OPEN ENDED QUESTION

3 mins • 1 pt

What will be the output of the code? #include int main() { int a = 5, b = 10; a = a + b; b = b - a; a = a - b; printf("a = %d, b = %d\n", a, b); return 0; }

Evaluate responses using AI:

OFF

2.

OPEN ENDED QUESTION

3 mins • 1 pt

Debug the code #include int main() { int a = 2; switch (a) { case 1: printf("One\n"); case 2: printf("Two\n"); case 3: printf("Three\n"); default: printf("Default\n"); } return 0; }

Evaluate responses using AI:

OFF

3.

OPEN ENDED QUESTION

3 mins • 1 pt

What will be the output of the code? #include int main() { int a = 257; char b = a; printf("b = %d\n", b); return 0; }

Evaluate responses using AI:

OFF

4.

OPEN ENDED QUESTION

3 mins • 1 pt

Fix the error #include int main() { int x = 10, y = 0; printf("%d", x / y); return 0; }

Evaluate responses using AI:

OFF

5.

OPEN ENDED QUESTION

3 mins • 1 pt

What will be the output of the code? #include int main() { int a = 5, b = 2; int result = a + b * 3; printf("Result = %d\n", result); return 0; }

Evaluate responses using AI:

OFF

6.

OPEN ENDED QUESTION

3 mins • 1 pt

Identify the issue with this code and suggest a fix. #include int main() { int i = 1; while (i <= 10); { printf("%d ", i); i++; } return 0; }

Evaluate responses using AI:

OFF

7.

OPEN ENDED QUESTION

3 mins • 1 pt

What will be the output of the code? #include int main() { int x = 5; printf("%d ", x++); printf("%d ", ++x); printf("%d\n", x--); return 0; }

Evaluate responses using AI:

OFF

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?