0
Java System.out.println output
System.out.println((1+"1")+1+1) Why output of this statement is 1111
1 ответ
+ 2
Because there is a string before the integer value
(11) + 1 + 1; here 11 inside braces is a string
1111
braces has higher preference so since there is no braces before 3rd 1 so that would be go with 11 which is string
If you add braces before 1 + 1 then output will be 112
System.out.println((1+"1")+(1+1));