输出带+号问题
为什么下面的程序输出带加号时输出的是ASCII值,而不到加号时正确输出;
还有为什么
当我定义数组的类型为字符串时输出带加号时语法错误
为什么下面的程序输出带加号时输出的是ASCII值,而不到加号时正确输出;
还有为什么
当我定义数组的类型为字符串时输出带加号时语法错误
2017-07-09
public void print(char s[]) {
write(s);
}
/**
* Prints a string. If the argument is <code>null</code> then the string
* <code>"null"</code> is printed. Otherwise, the string's characters are
* converted into bytes according to the platform's default character
* encoding, and these bytes are written in exactly the manner of the
* <code>{@link #write(int)}</code> method.
*
* @param s The <code>String</code> to be printed
*/
举报