"SCJP 1.6版考題 143" 修訂間的差異

出自 陳富國維基館
前往: 導覽搜尋
(新頁面: Given: System.out.printf("Pi is approximately %f and E is approximately %b, Math.PI, Math.E); Place the values where they would appear in the output. 檔案:SCJP143-1.png <div ...)
 
(無差異)

於 2013年3月30日 (六) 03:10 的最新修訂

Given: System.out.printf("Pi is approximately %f and E is approximately %b, Math.PI, Math.E);
Place the values where they would appear in the output.

SCJP143-1.png

解答


Ans:
SCJP143-2.jpg

解說:

%f float
%b boolean
System.out.printf 仿c時代的printf功能,指定格式輸出