Computer Applications
Describe the purpose and write the syntax of startWith() function.
Java String Handling
13 Likes
Answer
It tests if the string object starts with the string specified as its argument.
Syntax:
boolean <variable-name> = <string-variable>.startWith(<string>);
Answered By
7 Likes
Related Questions
Describe the purpose and write the syntax of reverse() function.
Describe the purpose and write the syntax of indexOf() function.
Describe the purpose and write the syntax of equalsIgnoreCase() function.
Write a program to input a sentence. Find and display the following:
(i) Number of words present in the sentence
(ii) Number of letters present in the sentence
Assume that the sentence has neither include any digit nor a special character.