Computer Applications
Describe the purpose and write the syntax of length() function.
Java String Handling
18 Likes
Answer
It returns the length of the string i.e. the number of characters present in the string.
Syntax:
int <variable-name> = <string-variable>.length();
Answered By
10 Likes