You are not logged in.

#1 2015-09-12 06:52:43

hasnain
Administrator
From: Chichawatni
Registered: 2014-10-13
Posts: 8,355
Website

Execution Of Program:

http://interviewquestionsanswers.org/quiz/C-Programming http://interviewquestionsanswers.org/qu … ge-Pointer

Directions:
void main()
{
   int a[10], i, *p;
   a[0] = 1;
   a[1] = 2;
   p = a;
   (*p)++;
}

Question:
Which of the following statements are true after execution of the program.

Option A):
a[1] = 2
Option B):
a[0] = 2
Option C):
a[1] = 3
Option D):
a[0] = 3

Correct Answer is Option B):
a[0] = 2


Failure is the first step towards seccess.

2015-09-12 06:52:43

Advertisement
Ads By Google

Re: Execution Of Program:



Board footer