Solved

Which Statement Prints the Floating-Point Value 123

Question 6

Multiple Choice

Which statement prints the floating-point value 123.456 right justified with a field width of 10?


A) System.out.printf("%d10.3", 123.456) ;
B) System.out.printf("%10.3d", 123.456) ;
C) System.out.printf("%f10.3", 123.456) ;
D) System.out.printf("%10.3f", 123.456) ;

Correct Answer:

verifed

Verified

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

Related Questions