1).what is the difference between below examples
String s="vijay";
String s=new String("vijay");
Answer Posted / p.sreekiran
in first string class it create in heep memory and second
is created object in constant memeory we cannot change the
second one
Is This Answer Correct ? | 2 Yes | 13 No |
Post New Answer View All Answers
What is the default size of arraylist in java?
What are disadvantages of java?
Is arraylist a class in java?
What is internal iteration in java se 8?
Do I need to import java.lang package any time? Why?
What is difference between identifier and variable?
What is the purpose of the file class in java programming?
When we should use serialization?
How to overcome the exception object reference not set to an instance of object?
Explain the selection sort algorithm and state its time complexity?
What's the difference between an abstract class and interface in java?
Write a factorial program using recursion in java?
Write a function for palindrome and factorial and explain?
Can you declare the main method as final?
Can final class have constructor?