(This question may be a duplicate but I really didn't understand the other answers)
You have the following code:
String str ="football";
str.concat(" game");
System.out.println(str); // it prints football
But with this code:
String str ="football";
str = str + " game";
System.out.println(str); // it prints football game
So what's the difference and what's happening exactly?