Mastering Programming Concepts

Mastering Programming Concepts

University

27 Qs

quiz-placeholder

Similar activities

Sharda fest 2024

Sharda fest 2024

University

25 Qs

CODEZILLA 2022

CODEZILLA 2022

University

30 Qs

C_Upto_Array

C_Upto_Array

University

25 Qs

Progdas-Q1-2023-2

Progdas-Q1-2023-2

University

25 Qs

XTK022

XTK022

University

25 Qs

Tech Forza

Tech Forza

University

25 Qs

kamala_bec

kamala_bec

University

30 Qs

C Programming

C Programming

University - Professional Development

30 Qs

Mastering Programming Concepts

Mastering Programming Concepts

Assessment

Quiz

Computers

University

Hard

Created by

Mr. Gogoi

FREE Resource

27 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the time complexity of accessing an element in an array?

O(n^2)

O(log n)

O(1)

O(n)

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a valid declaration of a pointer in C?

int ptr;

float *ptr = NULL;

char ptr;

int *ptr;

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code: int a = 5; printf('%d', a++);?

5.0

5

4

6

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the primary purpose of a stack data structure?

To store data in a First In, First Out (FIFO) manner.

To maintain a sorted list of elements.

To manage data in a Last In, First Out (LIFO) manner.

To allow random access to elements in any order.

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In C, how do you declare a function that returns an integer?

void functionName() {}

int functionName() {}

int functionName[] {}

function intName() {}

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will the following code print? int x = 10; printf('%d', ++x);

x

12

10

11

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which data structure uses LIFO (Last In, First Out) principle?

Queue

Linked List

Stack

Array

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?