Mastering Java: The Ultimate Quiz for 'Thinking in Java' 2025 - Free Java Programming Practice Questions and Study Guide

Image Description

Question: 1 / 510

Which operation can be used for both string concatenation and arithmetic addition in Java?

+

In Java, the + operator can be used for both string concatenation and arithmetic addition. This operator is most commonly associated with addition, but it can also be used to concatenate strings. The * and - operators are used for multiplication and subtraction, respectively. The += operator is a compound assignment operator, which combines addition and assignment. It is not used for string concatenation. Therefore, the correct answer would be A.

Get further explanation with Examzify DeepDiveBeta

*

-

+=

Next Question

Report this question

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy