waht is output | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 9

waht is output

public class Program { public static void main(String[] args) { int num1 = 7; int num2 = 9; num2 += num1; System.out.println(num2); for(num1=7;num1<=num2;num1++); num1++; System.out.println(num1); } }

12th Jun 2018, 2:29 PM
Shubham goyal
Shubham goyal - avatar
7 Answers
+ 7
Simply use the Code Playground to test your code snippets : )
12th Jun 2018, 2:51 PM
Ipang
+ 6
16 18
12th Jun 2018, 6:16 PM
Vegito
Vegito - avatar
+ 3
16 18 if not, let me know
12th Jun 2018, 3:06 PM
Sreejith P
Sreejith P - avatar
+ 1
ran it, confirmed it, it's 16 followed by 18
13th Jun 2018, 8:05 AM
DengSXCreates
DengSXCreates - avatar
- 2
the Ans Is 16 17
13th Jun 2018, 10:55 PM
Abdul Rehman
Abdul Rehman - avatar
- 2
1618
14th Jun 2018, 1:13 AM
Rahman Rezaie 🇦🇫
Rahman Rezaie 🇦🇫 - avatar
- 2
16 7
14th Jun 2018, 11:34 AM
ADIL GAAFER
ADIL GAAFER - avatar