Single Choice Not Set

QWhat is the output of the following println statement?
String str1 = "Hellow";
System.out.println(str1.indexOf('t'));

ID: #2218 String in Java 3,040 views
Question Info
#2218Q ID
Not SetDifficulty
String in JavaTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A true
  • B false
  • C 1
  • D -1
Correct Answer

Explanation

-1

Share This Question

Challenge a friend or share with your study group.