Hi guys , please look here . Consider code segment
String a=new String("SMS Message"); String b=new String("SMS Message"); if(a==b) System.out.println("they are equal");
i) why it does not generate an output ?
ii) how can we rewrite the program such that it will print the output ?