APTITUDE AND COMPANY PAPERS
This site provides concepts and answers to each question
Slideshow
Monday, 25 February 2013
Q.9 Consider the following code segment:
int a[10], *p1, *p2;
p1 = &a[4];
p2 = &a[6];
Which of the following statements is incorrect w.r.t. pointers?
(A) p1 + 2 (B) p2 – 2
(C) p2 + p1 (D) p2 – p1
Ans: C
Addition of two pointers is not allowed.
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment