14 dec 2023 SRMIST  TRC MCA    AN

14 dec 2023 SRMIST TRC MCA AN

Professional Development

15 Qs

quiz-placeholder

Similar activities

Shopping Vocabulary (1)

Shopping Vocabulary (1)

Professional Development

12 Qs

VRESEC-24.01.2024-AN-1-3

VRESEC-24.01.2024-AN-1-3

Professional Development

15 Qs

Test-3

Test-3

Professional Development

15 Qs

K10 - Game 1

K10 - Game 1

Professional Development

10 Qs

School objects

School objects

Professional Development

10 Qs

LIly Alan Walker song

LIly Alan Walker song

Professional Development

10 Qs

KN4  Unit 3 Vocabulary Lessons A-b

KN4 Unit 3 Vocabulary Lessons A-b

Professional Development

10 Qs

Mastering Python: Data Types & Functions

Mastering Python: Data Types & Functions

Professional Development

10 Qs

14 dec 2023 SRMIST  TRC MCA    AN

14 dec 2023 SRMIST TRC MCA AN

Assessment

Quiz

English

Professional Development

Hard

Created by

CCC info@ccc.training

Used 1+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int triangularNumber(int n) { if (n == 0) return 0; else return n + triangularNumber(n - 1); } int main() { printf("Triangular Number: %d\n", triangularNumber(3)); return 0; }
3
6
9
12

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int countDown(int n) { if (n <= 0) return 0; else { return 1 + countDown(n - 1); } } int main() { printf("Count Down: %d\n", countDown(4)); return 0; }
3
2
4
6

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int digitSum(int n) { if (n == 0) return 0; else return n % 10 + digitSum(n / 10); } int main() { printf("Digit Sum: %d\n", digitSum(567)); return 0; }
9
18
15
27

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int consecutiveSquaresSum(int n) { if (n == 0) return 0; else return n * n + consecutiveSquaresSum(n - 1); } int main() { printf("Consecutive Squares Sum: %d\n", consecutiveSquaresSum(3)); return 0; }
8
10
12
14

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int decimalToBinary(int n) { if (n == 0) return 0; else return n % 2 + 10 * decimalToBinary(n / 2); } int main() { printf("Binary Representation: %d\n", decimalToBinary(5)); return 0; }
100
101
110
111

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int palindromeCheck(int n) { if (n <= 0) return 1; else return n % 10 == (n / 10) % 10 && palindromeCheck(n / 100); } int main() { printf("Palindrome Check: %d\n", palindromeCheck(1221)); return 0; }
0
1
10
11

7.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

int sumOfEvenDigits(int n) { if (n == 0) return 0; else return (n % 10 % 2 == 0 ? n % 10 : 0) + sumOfEvenDigits(n / 10); } int main() { printf("Sum of Even Digits: %d\n", sumOfEvenDigits(123456)); return 0; }
10
15
12
11

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?