Computer Science, asked by idk92, 7 months ago

3. The following is a segment of a Program:
int A=1,B=1,N;
if(N>0)
A=A+1;
A=B-1;
What will be the value of A and B, if N assumes a value
i) 1 ii) 0?​

pls its my exam

Answers

Answered by mythilir2011
0

Answer

if N value is 1 then A=0 and B=1

if N value is 1 then A=0 and B=1if N value is 0 then A= 1 and B=1

Similar questions