JAVA Strings String str1 = "Kolkata".replace('k', 'a');In the above statement, the effect on string Kolkata is All characters k are replaced by a. All characters a are replaced by k. Displays error message The first occurrence of k is replaced by a. All characters k are replaced by a. All characters a are replaced by k. Displays error message The first occurrence of k is replaced by a. ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings The String method compareTo() returns an int value -1 1 false true an int value -1 1 false true ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings The output of the following fraction of code ispublic class Test{ public static void main(String args[]){ String s1 = new String("Hello");String s2 = new String("Hellow");System.out.println(s1 = s2);}} Hellow Hello Compilation error None of these Throws an exception Hellow Hello Compilation error None of these Throws an exception ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings The class string belongs to ................. package. java.lang java.applet java.string java.awt java.lang java.applet java.string java.awt ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings What is the output of the following println statement?String str1 = "Hellow";System.out.println(str1.indexOf('t')); true 1 false -1 0 true 1 false -1 0 ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings How many Constructor String class have? 2 13 None of this 11 7 2 13 None of this 11 7 ANSWER DOWNLOAD EXAMIANS APP