Engineering Full Stack Apps with Java and JavaScript
What will the following code print when compiled and run
public class TestClass { public static void main(String[] args){ while(int k = 5; k<7){ System.out.println(k++); } } }
Select 1 option
A. 5
6
B. 5
6
7
C. It will keep printing 5.
D. It will not compile.
E. It will throw an exception at run time.