public static void main(String[] args) { try { args=null; args[0] = “test”; System.out.println(args[0]); } catch (Exception ex) { System.out.println(”Exception”); } catch (NullPointerException npe) { System.out.println(”NullPointerException”); } } What is the result?()
- A、 test
- B、 Exception
- C、 Compilation fails.
- D、 NullPointerException
正确答案:C
答案解析:有

微信扫一扫手机做题