public class X {   public static void main (Stringargs) {   string s = new string (“Hello”);   modify(s);   System.out.printIn(s);   }   public static void modify (String s) {   s += “world!”;   }   }   What is the result?() 

A . The program runs and prints “Hello” B . An error causes compilation to fail. C . The program runs and prints “Hello world!” D . The program runs but aborts with an exception.

时间:2022-11-08 15:40:43 所属题库:SCJP程序员认证考试题库

相似题目