ExamLookup
Menu mobile
Home
Current Affairs
General Knowledge
Computer
Python
HTML
MCQ C - POINTERS MCQ Questions
English
Hindi
Question No. -
21
Report Bug
Structures cannot contain a pointer to itself.
Structures cannot contain a pointer to itself.
A.
TRUE
सही
B.
FALSE
गलत
Explanation
Structure can contain a Pointer to itself. Such structures are called self-referential structures.
Question No. -
22
Report Bug
Which of the following is a wrong pointer declaration?
Which of the following is a wrong pointer declaration?
A.
int *int(a);
int *int(a);
B.
int *x, *y;
int *x, *y;
C.
float *aptr;
float *aptr;
D.
int *x; float *y;
int *x; float *y;
Question No. -
23
Report Bug
In the declaration int(*p)() p is a pointer to a function that returns an integer.
In the declaration int(*p)() p is a pointer to a function that returns an integer.
A.
TRUE
सही
B.
FALSE
गलत
Question No. -
24
Report Bug
How will you free the allocated memory?
How will you free the allocated memory?
A.
remove(var-name);
remove(var-name);
B.
free(var-name);
free(var-name);
C.
delete(var-name);
delete(var-name);
D.
dalloc(var-name);
dalloc(var-name);
Question No. -
25
Report Bug
In ‘C’, if you pass an array as an argument to a function, what actually gets passed?
In ‘C’, if you pass an array as an argument to a function, what actually gets passed?
A.
Value of elements in array
Value of elements in array
B.
First element of the array
First element of the array
C.
Base address of the array
Base address of the array
D.
Address of the last element of array
Address of the last element of array
Question No. -
26
Report Bug
The three declarations char **apple, char *apple[], and char apple[][] are same.
The three declarations char **apple, char *apple[], and char apple[][] are same.
A.
TRUE
सही
B.
FALSE
गलत
Question No. -
27
Report Bug
malloc() returns a float pointer if memory is allocated for storing float's and a double pointer if memory is allocated for storing double's.
malloc() returns a float pointer if memory is allocated for storing float's and a double pointer if memory is allocated for storing double's.
A.
TRUE
सही
B.
FALSE
गलत
Question No. -
28
Report Bug
What will be the output of the following code?
main() { int c,d, *p1=&c,*p2=&d, x;
c =10,d =4;
x = –3* – *p2 / *p1 + 5;
printf(“%d ”,x);
}
What will be the output of the following code?
main() { int c,d, *p1=&c,*p2=&d, x;
c =10,d =4;
x = –3* – *p2 / *p1 + 5;
printf(“%d ”,x);
}
A.
6
6
B.
Invalid syntax because / * is used for comments.
Invalid syntax because / * is used for comments.
C.
8
8
D.
IInvalid syntax because three binary operators can’t be together in an
expression.
IInvalid syntax because three binary operators can’t be together in an
expression.
Question No. -
29
Report Bug
The return type of malloc function is void.
The return type of malloc function is void.
A.
TRUE
सही
B.
FALSE
गलत
Question No. -
30
Report Bug
Size of the pointer variable depends on the data type that it points to.
Size of the pointer variable depends on the data type that it points to.
A.
TRUE
सही
B.
FALSE
गलत
1
2
3
4
5
6
CCC Online Test 2021
CCC Practice Test Hindi
Python Programming Tutorials
Best Computer Training Institute in Prayagraj (Allahabad)
O Level NIELIT Study material and Quiz
Bank SSC Railway TET UPTET Question Bank
career counselling in allahabad
Sarkari Exam Quiz
Website development Company in Allahabad