hc学习平台

 找回密码
 立即注册
搜索
热搜: 活动 交友 javakc
 › xxxxxx › 日志

What  is  the  result?  

2022-08-16 20:44:54 查看(79) 回复(0)

public  class  Foo{  
    public  static  void  main(String  sgf[  ]){  
        StringBuffer  a  =  new  StringBuffer("A");  
        StringBuffer  b  =  new  StringBuffer("B");  
        operate(a,b);  
        System.out.println(a+"."+b);  
    }  

    static  void  operate(StringBuffer  x,StringBuffer  y){  
        x.append(y);  
        y=x;  
    }  
}  
A、The  code  compiles  and  prints  "A.A"  
B、The  code  compiles  and  prints  "AB.B"
C、The  code  compiles  and  prints  "AB.AB"
D、The  code  compiles  and  prints  "A.B"
E、The  code  compiles  and  prints  "B.B"    
B

评论 (0 个评论)

facelist

全部作者的其他最新日志



站点统计|举报|Archiver|手机版|小黑屋|Comsenz Inc.

GMT+8, , Processed in 0.195171 second(s), 9 queries .

Powered by javakc! X1.0

© 2004-2014 javakc

f1208.com 备案号:京ICP备14030918号-1

返回顶部