B

Bhagwan Das • 4.44K Points
Extraordinary

Q. How do you check if a string contains a specific character in Java?

  • (A) str.contains(char)
  • (B) str.indexOf(char)
  • (C) str.hasChar(char)
  • (D) str.charExists(char)
  • Correct Answer - Option(A)
  • Views: 37
  • Filed under category JAVA

No solution found for this question.
Add Solution and get +2 points.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.


Question analytics