C Arrays

C Arrays

University

36 Qs

quiz-placeholder

Similar activities

CS 131 - Set 2

CS 131 - Set 2

University

34 Qs

Round 1 (Computer)

Round 1 (Computer)

University

40 Qs

DSA CSE quiz

DSA CSE quiz

University

40 Qs

C++ Functions and Arrays Quiz

C++ Functions and Arrays Quiz

University

34 Qs

Java Basico

Java Basico

University

32 Qs

Structures and Pointers in C

Structures and Pointers in C

University

35 Qs

IOT_SARS

IOT_SARS

University

40 Qs

DDP UA

DDP UA

University

35 Qs

C Arrays

C Arrays

Assessment

Quiz

Computers

University

Hard

Created by

sandeep aggarwal

Used 31+ times

FREE Resource

36 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Arrays are structures that hold multiple variables of the _____________ data type

int data type

char data type

same data type

different data type

2.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

The first element in the array is by default numbered (index)

_____

-1

0

1

anything by the programmer

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Before using an array its type and dimension must be declared?

True

False

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

int marks[30]; What the number 30 tells us

int data type size

number of elements in marks array

maximum value, that can stored in marks

None

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one is correct syntax for accessing value of 2nd element of an array

int value = marks[1];

int value = marks[2];

int value = marks(1);

int value = marks(2)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one is correct syntax for entering 30 at 10th position of an array?

marks[10]=30

marks[9]=29

marks[9]=30

marks[10]=29

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Predict output of following program

int main(){

int i;

int arr[5] = {1};

for (i = 0; i < 5; i++)

printf("%d ", arr[i]);

return 0;

}

1 1 1 1 1

1 followed by 4 junk values

1 0 0 0 0

Compiler error

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?