Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

13. If a program compiles fine, but it produces incorrect result, then the program suffers_ a. a compilation error b. a runtime error c. a

image text in transcribed
image text in transcribed
13. If a program compiles fine, but it produces incorrect result, then the program suffers_ a. a compilation error b. a runtime error c. a logic error d. None of the above. 14. What is the exact output of the following codei? double area 3.5 System.out.printf("area") System.out.print(area) a. 3.53.5 b. 3.5 3.5 c. area3.5 d. area 3.5 15. Suppose a Scanner object is created as follows: Scanner input - new Scanner(System.in); What method do you use to read a real number? a. input.nextDouble): b. input.nextdouble(): c. input.double) d. input.Double(): 16. To declare a constant MAX_LENGTH inside a method with value 99.98, you write a. final MAX LENGTH 99.98 b. final float MAX LENGTH 99.98; c. double MAX LEN GTH 99.98 d. final double MAX LENGTH 99.98; 17. According to Java naming convention, which of the following names can be variables? a. FindArea b. Find_area c. totallength d. TOTAL LENGTH 13. If a program compiles fine, but it produces incorrect result, then the program suffers_ a. a compilation error b. a runtime error c. a logic error d. None of the above. 14. What is the exact output of the following codei? double area 3.5 System.out.printf("area") System.out.print(area) a. 3.53.5 b. 3.5 3.5 c. area3.5 d. area 3.5 15. Suppose a Scanner object is created as follows: Scanner input - new Scanner(System.in); What method do you use to read a real number? a. input.nextDouble): b. input.nextdouble(): c. input.double) d. input.Double(): 16. To declare a constant MAX_LENGTH inside a method with value 99.98, you write a. final MAX LENGTH 99.98 b. final float MAX LENGTH 99.98; c. double MAX LEN GTH 99.98 d. final double MAX LENGTH 99.98; 17. According to Java naming convention, which of the following names can be variables? a. FindArea b. Find_area c. totallength d. TOTAL LENGTH

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle 10g Database Administrator Implementation And Administration

Authors: Gavin Powell, Carol McCullough Dieter

2nd Edition

1418836656, 9781418836658

More Books

Students also viewed these Databases questions