Computer Science, asked by duraisanthoshs51, 1 year ago

13. Give the output of the program snippet.
int a = 10, b =12;
if(a>=10)
a++;
else
++b;
System.out.println(" a = " + a + "and b =" +b)​

Answers

Answered by Lazarus
21

Answer:

HEYA MATE HERE'S YOUR REQUIRED ANSWER:-

a will be always greater than equal to 10

a=11.....to infinite positive value ....

if a is less than 10

b=13

HOPE THIS HELPS...

(NOTE:- IF YOU HAVE A BLUEJ APP IN YOUR COMPUTER DESKTOP USE THIS PROGRAM TO FIND THE EXACT OUTPUT OF YOUR QUESTION.)


duraisanthoshs51: Plz accept my request
Lazarus: what request?
duraisanthoshs51: Follow req
Lazarus: pls mark my answer BRAINLIEST if u have doubts u can follow me but generally I don't follow others
duraisanthoshs51: Bro
Answered by kushal4468
4

Answer:

a = 11 and b = 12

Explanation:

The condition if(a>=10) is true so a++ increments a to 11. b remains the same.

Similar questions