VOOZH about

URL: https://www.geeksforgeeks.org/scala/scala-string-subsequence-method-with-example/

⇱ Scala String subSequence() method with example - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Scala String subSequence() method with example

Last Updated : 23 Oct, 2019
The subSequence() method is utilized to find the sub-sequence from the given String, And this sub-sequence starts and ends with the index we specify.
Method Definition: CharSequence subSequence(int beginIndex, int endIndex) Return Type: It returns the resultant sub-sequence.
Example: 1#
Output:
for
Example: 2#
Output:
forGeeks
Comment
Article Tags:

Explore