• +91 9723535972
  • info@interviewmaterial.com

Regular Expressions Interview Questions and Answers

Question -
What is Matcher class?



Answer -

Matcher Class helps in performing match operations on a character sequence.The method description is as follows:
  • boolean matches() used in testing the regular expression which matches the pattern.
  • boolean find() helps in finding the next expression which matcges the pattern.
  • boolean find(int start) used in finding the next expression which matches the pattern from given the start number.
  • String group() helps in returning the matched subsequence.
  • int start() helps in returning the starting index of the matched subsequence.
  • int end() helps in returning the ending index of the matched subsequence.
  • int groupCount() helps in returning the total number of the matched subsequence.

Comment(S)

Show all Coment

Leave a Comment




NCERT Solutions

 

Share your email for latest updates

Name:
Email:

Our partners