You are not logged in.

#1 2015-04-18 05:24:08

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

Output Of The Program?

Directions:

#define INC(X) X++
void main()
{
   int x=4;
   printf("%d", INC(x++));
}

Question:
Find the output of the following program.

Option A):
4
Option B):
6
Option C):
5
Option D):
Error

Correct Answer is Option D):
Error

Explanation:
L value is required for this expression (x++++) which is illegal.


Failure is the first step towards seccess.

2015-04-18 05:24:08

Advertisement
Ads By Google

Re: Output Of The Program?



\n

Board footer