多选题 Given:
2. import java.text.*;
3. public class Gazillion {
4. public static void main(String[] args) throws Exception {
5. String s = "123.456xyz";
6. NumberFormat nf = NumberFormat.getInstance();
7. System.out.println (nf.parse(s));
8. nf.setMaximumFractionDigits(2);
9. System.out.println (nf.format(s));
10. }
11. }
Which are true? (Choose all that apply.)
【正确答案】 C、E
【答案解析】