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);}} Hello None of these Throws an exception Compilation error Hellow Hello None of these Throws an exception Compilation error Hellow ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings What will be the output?public class Test{ public static void main (String[] args){ String test = "a1b2c3"; String[] tokens = test.split("\\d"); for(String s: tokens) System.out.print(s); } } abc 123 Compilation error Runtime exception thrown abc 123 Compilation error Runtime exception thrown ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings What will be output?String S1 = "S1 ="+ "123"+"456";String S2 = "S2 ="+(123+456); S1=123456,S2=123456 S1=579,S2=579 None of This S1=123456, S2=579 S1=123456,S2=123456 S1=579,S2=579 None of This S1=123456, S2=579 ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings The class string belongs to ................. package. java.applet java.awt java.lang java.string java.applet java.awt java.lang java.string ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings How many Constructor String class have? None of this 2 13 7 11 None of this 2 13 7 11 ANSWER DOWNLOAD EXAMIANS APP
JAVA Strings toString() method is defined in java.lang.util java.lang.Object java.lang.String None of these java.lang.util java.lang.Object java.lang.String None of these ANSWER DOWNLOAD EXAMIANS APP