C Quiz-IT-B(Arrays & Pointers)

C Quiz-IT-B(Arrays & Pointers)

University

10 Qs

quiz-placeholder

Similar activities

Rapid Round 2

Rapid Round 2

University

10 Qs

Java Programming

Java Programming

University

15 Qs

Array 2: Unit 8

Array 2: Unit 8

University

6 Qs

Unit-2: Assignment 2

Unit-2: Assignment 2

University

15 Qs

JAVA array

JAVA array

12th Grade - University

10 Qs

RVS_Tech_quizz_even2024-25

RVS_Tech_quizz_even2024-25

University

10 Qs

Milking Minds 2 17-01-24

Milking Minds 2 17-01-24

University

15 Qs

Arrays

Arrays

University

6 Qs

C Quiz-IT-B(Arrays & Pointers)

C Quiz-IT-B(Arrays & Pointers)

Assessment

Quiz

Computers

University

Medium

Created by

roja laveti

Used 4+ times

FREE Resource

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for declaring a pointer in C?

int ptr;


ptr = int;


int *ptr();


int *ptr;

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the size of a pointer variable in C?

4 bytes (on a 32-bit system) or 8 bytes (on a 64-bit system)

10 bytes

2 bytes


16 bytes

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What do the following declaration signify?

char *arr[10];

arr is a array of 10 character pointers.


arr is a array of function pointer.

arr is a array of characters.


arr is a pointer to array of characters.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for declaring an array in C?


array_name = [array_size];

array_name = data_type[array_size];


array_name[array_size] = data_type;

data_type array_name[array_size];

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the difference between array and pointer in C?

Arrays are a fixed-size collection of elements, while pointers are variables that store memory addresses.

Arrays cannot be passed as arguments to functions, while pointers can

Arrays can only store integers, while pointers can store any data type

Arrays and pointers are the same thing

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Choose a correct array statement.


An array size can not changed once it is created.


Array element value can be changed any number of times

To access Nth element of an array students, use students[n-1] as the starting index is 0.

All the options

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of C Program.?

int main()

{

int a[];

a[4] = {1,2,3,4};

printf("%d", a[0]);

}

1


Compiler Error

4

2

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?