賦值運算符
public class HelloWorld{
??? public static void main(String[] args) {
???? int one = 10 ;
??????? int two = 20 ;
???
??????? int three=one+two;
??????? int three+=one;
?????? System.out.println(three);錯誤是這個? error: ';' expected
? ? ? ?int three += one ;
? ? ? ? ? ? ? ? ^
error: not a statement
? ? ? ?int three += one ;
? ? ? ? ? ? ? ? ? ? ^
2 errors
2015-04-28
你已經(jīng)一個?int three 了,把第二個 int three換一個名字