+ 1

What is the output in this code? And how?

int result =0; for (int i=0;i<5;i++) { If (i==3){ result + = 10; } else { result+=i; } System.out.println (resul) ;

16th Oct 2019, 4:57 PM
Ali Idress
Ali Idress - avatar
1 Respuesta
+ 1
17 Value of result in every cycle 0+1+2+10+4
16th Oct 2019, 5:08 PM
id001x
id001x - avatar