English

Predict Output of Following Program Segment. - Structured Programming Approach

Advertisements
Advertisements

Question

Predict output of following program segment.

main()
{
int x=4, y=9,z;
clrscr();
z=x++ + --y+y;
printf("\n%d%d%d",x,y,z);
z= --x+x+y--;
printf("\n%d%d%d",x,y,z);
getch();
}

Short Note

Solution

Output:
5820
4716

shaalaa.com
Data Input and Output in C-Programming
  Is there an error in this question or solution?
2017-2018 (June) CBCGS

APPEARS IN

Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×
Our website is made possible by ad-free subscriptions or displaying online advertisements to our visitors.
If you don't like ads you can support us by buying an ad-free subscription or please consider supporting us by disabling your ad blocker. Thank you.