length() method example- Core Java
Q. The following program is an example of?
class Simple{
public static void main(String args[]){
String s="Sachin";
System.out.println(s.length());//6
}
} - Published on 20 Jul 15a. length() method
b. intern() method
c. trim() method
d. charAt() method
ANSWER: length() method