String [] s = new String[1];
s[0] = "a";
fun(s);void fun(Stirng [] s){
s[0] = "aaaa";
}
s[0] = "a";
fun(s);void fun(Stirng [] s){
s[0] = "aaaa";
}
解决方案 »
- 关于java 串口
- 求高手,Java目录结构求解~
- 关于面相对象设计
- 菜鸟关于异常的问题
- 二进制(OutputStream)字节移位的疑惑(请教高手)
- SOS 使用eclipse时Jboss怎么安装配置呀,eclipse-examples-2.1.1-win32.zip.md5怎么解压?谢谢
- 急!有关参考书,50分酬谢
- jbuilder6用了几天后,再起动时出现unknown license file format,如何解决
- 问个很菜的问题!
- 如何在applet中捕获鼠标右键的单击和左键的双击事件
- 请问如何获得当前java运行环境的路径?
- 急!!! 关于Runtime.getRuntime().exec(command)的问题! 急死人了!
for(int j = 0; j < i - 1; j++) { //i为生成的次数
s = s+sTemp;
}
char chr='a';
int Count=3;
System.out.println(getStr(chr,Count));
}
public static String getStr(char chr,int Count)
{
String Result="";
for(int i=0;i<Count;i++)
{
Result+=chr;
}
return Result;
}
}
int length=3;
StingBuffer strb= new StringBuffer();
for (i=0 ;i<length;i++ )
{
strb.append('a');
}
String str=strb.toString();
System.out.println(str);
void test(int num){
for(int i=1;i<num;i++){
temp+=temp;
}
}
test(3);
System.out.println(temp);
StringBuffer sb = new StringBuffer("a");
String value = sb.toString();
sb.clear();
int count = 3;
for(int i=0;i<count;i++){
sb.append(value);
}
sb.toString();