Multiple choice

Which of the following functions is/are valid in Java for Strings?

  1. valueOf()

  2. toCharArray()

  3. toIntArray()

  4. both 1 and 2

  5. both 1 and 3

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

As I explained that both 1 & 2 options are valid functions in java.So this is the correct answer.