Question: String sentence; String str1, str2, str3, str4; int length1; sentence = First test is on Monday.; str1 = sentence.substring(6, 12); str2 = str1.substring(0, 4); str3

String sentence; String str1, str2, str3, str4; int length1; sentence = "First test is on Monday."; str1 = sentence.substring(6, 12); str2 = str1.substring(0, 4); str3 = sentence.replace('i', '#'); str4 = sentence.indexOf("on"); length1 = sentence.length(); Based on the code above, what is the value of str4?

options:

11

12

13

14

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!