Java OCA OCP Practice Question 47

Question

Which of the following methods cause the String object referenced by s to be changed?

  • A. s.concat()
  • B. s.toUpperCase()
  • C. s.replace()
  • D. None of the above


D

Note

String objects are immutable and cannot be changed.




PreviousNext

Related