How do you extract the first 5 characters from the string str?
A) substring(str, 5)
B) substring.str(0,5)
C) str.substring(5)
D) str.substring(0,5)
Correct Answer:
Verified
Q112: Which operator is used to concatenate two
Q113: Which of the given System.out.print statements generates
Q114: What is the output of the following
Q115: Which one of the following expressions can
Q116: How do you compute the length of
Q118: What is the output of the following
Q119: Which of the methods below are static
Q120: What is the output of the following
Q121: Assume the following variables have been declared
Q122: What is the correct way to invoke
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents