edited by
284 views
0 0 votes

Which of the following statements about pointers in $C$ are TRUE.

  1. Pointers can be used to access array elements
  2. Pointers can store the address of another pointer
  3. Pointers are automatically deferenced in expression
  4. Pointers cannot be used to access structure members
Choose the correct answer from the options given below:
  1. $(I)$ and $(III)$ Only
  2. $(I)$ and $(II)$ Only
  3. $(II)$ and $(III)$ Only
  4. $(III)$ and $(IV)$ Only

1 Answer

1 1 vote
A B are correct options.

C option false due to dereference operator * must be mention while declaring a pointer if you not mention * then the complier treating as a variable.

D false
Answer:
Position:
Show:

Related questions

1 1 vote
2 2 answers
374
374 views
Shubham Sharma 2 asked Sep 9, 2025
374 views
#include<stdio.h void main() { int arr[]={1, 2, 3, 4, 5}; int *p=arr; printf("%d", *p++); printf("%d", *(p+1)); }Find the output of the above code?$1,2$$1,3$$2,3$$1,4$
0 0 votes
2 2 answers
386
386 views
Shubham Sharma 2 asked Sep 9, 2025
386 views
Consider the following code:#include<stdio.h void f1(char *x, char *y) { char *t1; t 1 = x; x= y; y = t 1;} void f2(char x, char y) { char *t1 ; t1 = *x; *x = *y; *y = ...
0 0 votes
1 1 answer
335
335 views
Shubham Sharma 2 asked Sep 9, 2025
335 views
Consider following C program :#include<stdio.h int main() { int x[]={2,4,6,8,10}; int a, b=0, * y = x+4; for(a = 0; a<5; a++) { b=b+(*y -a) - *(y -a); } printf("%d\n", b)...
0 0 votes
1 1 answer
235
235 views
Shubham Sharma 2 asked Sep 9, 2025
235 views
Which of the following is correct way to declare a functional pointer in C?int *func (int, int);int (*func) (int, int);int (func*) (int, int);int *func* (int, int);