Example

public class ClassA {
Strings; Strings2; public void methodA {

String s2 = s.substring(0);
}

}
Solution s.substring(0) willr eturn the string s. Reconsider your use of the substring() method.