void main()
{ int x=4,y,z:
y=--x;
z=x--;
}
what is the output

Answers were Sorted based on User's Feedback



void main() { int x=4,y,z: y=--x; z=x--; } what is the output..

Answer / praveen kumar d

no output because no printf()
if we print y and z
the output is :
y=3
z=3

Is This Answer Correct ?    28 Yes 4 No

void main() { int x=4,y,z: y=--x; z=x--; } what is the output..

Answer / narayanan

Y=3 \ initially Y=0 then Y = --x Decremented then assigning value so Y=3

Z=3 \z = x-- assigning x value to z first then Decremented so Z=3

Is This Answer Correct ?    7 Yes 1 No

void main() { int x=4,y,z: y=--x; z=x--; } what is the output..

Answer / sowmya

What will be the value of x

Is This Answer Correct ?    3 Yes 0 No

void main() { int x=4,y,z: y=--x; z=x--; } what is the output..

Answer / nirmal

y=3
z=2

Is This Answer Correct ?    2 Yes 6 No

Post New Answer

More GATE Interview Questions

I have lost my SSC and +2 certificates could i know how to get them, my education is basically from andhra, is there any web site of governament to get my copies since i am outside my state? please any one guide me, thanks in advance

0 Answers  


how many key in key board

5 Answers  


Sir Pl Provide the diploma nautical science sample paper

0 Answers  


lovers love it , friends need it relationship starts with it, life ends with it it is?

3 Answers   Invensys,


send the instrumentation branch model question paper at the last year paper

1 Answers   HPCL,






Which one of the following Union Ministries launched the Eco-Mark scheme for labeling the consumer products? (1) Ministry of Agro and Rural Industries (2) Ministry of Environment and Forests (3) Ministry of Food Processing Industries (4) Ministry of Consumer Affairs, Food and Public Distribution.

2 Answers   IES,


Tripura Board of Secondary Education Agartala, Tripura Examination Results 2009 Tripura Board of Secondary Education Higher Secondary (+2 Stage) Examination - Year 2009

0 Answers  


what reason to change compnay ?

3 Answers  


what does JComponent.invalidate()or JComponent.invalidate()do?

1 Answers  


How can i calculate the Multifactor in HT meter? Pls tell me the Formullas.

1 Answers   HCL,


how to prepare gate in a week

2 Answers   GATE,


why the uncontrolled rectifiers are converting fixed ac to fixed dc only why not it is converting variable dc

0 Answers   NPCIL,


Categories