Solved

How Do You Fix This Code Snippet to Make It

Question 66

Multiple Choice

How do you fix this code snippet to make it print out the sum when the user enters a letter rather than a double? The user must enter at least one double when the program begins. How do you fix this code snippet to make it print out the sum when the user enters a letter rather than a double? The user must enter at least one double when the program begins.    A) while (in.hasData() ) ; B) while (!in.hasEnded() ) ; C) while (in.hasNextDouble() ) ; D) while (hasData) ;


A) while (in.hasData() ) ;
B) while (!in.hasEnded() ) ;
C) while (in.hasNextDouble() ) ;
D) while (hasData) ;

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