日期:2014-05-20 浏览次数:20758 次
public class Test10
{
public static void main(String[] args)
{
String a = "hello";
Method method = new Method();
method.execute(a);
System.out.println(a);
}
}
class Method
{
public void execute(String name)
{
name = "world";
}
}
public class Test10
{
public static void main(String[] args)
{
String a = "hello";
Method method = new Method();
a = method.execute(a);
System.out.println(a);
}
}
class Method
{
public String execute(String name)
{
return "world";
}
}