What is the output of the following Java code?int num = 15;
While (num > 0)
Num = num - 3;
System.out.println(num) ;
A) 0
B) 3
C) 12
D) 15
Correct Answer:
Verified
Q26: After a break statement executes, the program
Q28: int sum = 0;int limit = console.nextInt();
Int
Q29: int i;for (i = 0; i <=
Q30: int i;for (i = 0; i <=
Q33: If a continue statement is placed in
Q34: The do...while loop has an exit condition
Q35: Suppose sum and num are int variables,
Q36: ch = inFile.next().charAt();while (inFile.hasNext())
{
System.out.println(ch);
Ch = inFile.next().charAt();
}The above
Q37: What is the value of counter after
Q38: A break statement is legal in a
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents