Q. What is the output of the following code?
Code:String s1 = “Hello”; String s2 = “World”; String s3 = s1 + s2; System.out.println(s3);
β
Correct Answer: (A)
HelloWorld
Explanation: The values of s1 and s2 are concatenated to form s3, which is then printed.