-
What is the output of this program?
public class String_Example
{
public static void main(String args[])
{
char chars[] = {'I', 'L', 'U'};
String obj = new String(chars);
String obj1 = "InterviewMania";
int len0 = obj1.length();
int len1 = obj.length();
System.out.println(len0 + " " + len1);
}
}
-
- 14 3
- 3 14
- 41 3
- 3 41
- None of these
Correct Option: A
Output: 14 3