ISRO Scientist/Engineer CSE 2023Programming in C › Not yet assigned to a topic
ISRO Scientist/Engineer CSE 2023 PYQ: Pointer $p$ to an array of integers (of size 2 Bytes) is initialised to 200. What is the value of…
Pointer $p$ to an array of integers (of size 2 Bytes) is initialised to 200. What is the value of $\mathrm{p}+3$ ?
- A206Correct answer
- B203
- C212
- D204
Answer
(A) $206$
Approach
Pointer arithmetic on a typed pointer scales the integer offset by the size of the pointed-to element. Since each integer occupies 2 bytes and p starts at address 200, p+3 advances by 3 × 2 = 6 bytes.
Reviewed by ISRO IQ Editorial Team.