I\'m new to Java. What does the below mean?
(addition) + sign in println
System.out.println ("Count is: " + i);
The + in arithmetic adds 2 numbers together, like this:
2 + 2 = 4
now apply the same thing to a string:
"hello " + "world!" = "hello world!"
now adding strings and variables will do this:
int number = 4;
String string = "what was the number? oh yeah: "+number;
System.out.println(string);
if all goes well you should get "what was the number? oh yeah: 4"
Java took the value of the variable and put it into the string for you, hope this helped!