Solved

Assuming That a User Enters 15 as Input, What Is

Question 19

Multiple Choice

Assuming that a user enters 15 as input, what is the output of the following code snippet? Scanner in = new Scanner(System.in) ;
System.out.print("Please enter a number: ") ;
Int number = in.nextInt() ;
If (number > 20)
{
System.out.println("The number is LARGE!") ;
}
Else
{
System.out.println("The number is SMALL!") ;
}


A) There is no output due to compilation errors.
B) The number is LARGE!
C) The number is SMALL!
D) The number is LARGE!
The number is SMALL!

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions

Unlock this Answer For Free Now!

View this answer and more for free by performing one of the following actions

qr-code

Scan the QR code to install the App and get 2 free unlocks

upload documents

Unlock quizzes for free by uploading documents