Examlex

Solved

String Sentence; String Str1, Str2, Str3, Str4;

question 30

Multiple Choice

String sentence;
String str1, str2, str3, str4;
Int length1;sentence = "First exam 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?


Definitions:

Homo Floresiensis

A species of small, extinct hominids, known as "hobbits," discovered on the Indonesian island of Flores, notable for their small size and ancient lineage.

Fossil Record

The collection of fossils, which serves as historical documentation of past life on Earth.

Stone Tools

Prehistoric tools made from stone by early humans, used in hunting, cutting, and as weapons.

Related Questions