State the Output of the Following Program Segment: String Str1 = “Great”; String Str2 = “Minds”;
Advertisements
प्रश्न
State the output of the following program segment:
String str1 = “great”; String str2 = “minds”;
System.out.println (str1.substring (0,2).concat(str2.substring (1)));
System.out.println ((“WH”+(str1.substring (2).toUpperCase())));
एक पंक्ति में उत्तर
Advertisements
उत्तर
The output is as follows:
grinds
WHEAT
shaalaa.com
क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
