Does substring create a new object?



Does substring create a new object?..

Answer / Aditya Kumar Kushwaha

Yes, substring() creates a new string object that contains a sub sequence of the original string.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

What is diffrance between FINALIZE() & FINALLY ?

2 Answers   Infosys,


Why should we use singleton pattern instead of static class?

1 Answers  


what do you mean by marker interface in java?

1 Answers  


What are checked exceptions?

1 Answers  


Make a data structure and implement an algorithm to print all the files in a directory. (The root directory can have sub-directories too.)

1 Answers   Amazon,


What are the steps involved to write rmi based programs?

1 Answers  


Which programming language is best in future?

1 Answers  


Why is singleton not thread safe?

1 Answers  


What is a void method?

1 Answers  


What is the use of Getters and Setters method ?

4 Answers  


Is array dynamic in java?

1 Answers  


What is passed by reference and pass by value ?

1 Answers  


Categories