in Education by
Which of the following is not a class of java.util.regex? (a) Pattern class (b) matcher class (c) PatternSyntaxException (d) Regex class This question was posed to me by my school principal while I was bunking the class. This interesting question is from Regular Expression in section Regular Expressions of Java Select the correct answer from above options

1 Answer

0 votes
by
 
Best answer
Correct answer is (d) Regex class Explanation: java.util.regex consists 3 classes. PatternSyntaxException indicates syntax error in regex.

Related questions

0 votes
    What is the significance of Matcher class for regular expression in java? (a) interpretes pattern in the string ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of the following matches nonword character using regular expression in java? (a) \w (b) \W (c) \ ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of the following matches end of the string using regular expression in java? (a) \z (b) \\ (c ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of these package is used for text formatting in Java programming language? (a) java.text (b) java. ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of this class can be used to format dates and times? (a) Date (b) SimpleDate (c) DateFormat (d ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of these class allows us to define our own formatting pattern for dates and time? (a) DefinedDateFormat ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of these formatting strings of SimpleDateFormat class is used to print AM or PM in time? (a) a (b ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Object of which class is used to compile regular expression? (a) Pattern class (b) Matcher class (c) ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of these method returns an instance of DateFormat that can format time information? (a) getTime() (b) ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which capturing group can represent the entire expression? (a) group * (b) group 0 (c) group * or ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    groupCount reports a total number of Capturing groups. (a) True (b) False I had been asked this question ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    What does public int end(int group) return? (a) offset from last character of the subsequent group (b) ... Regular Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    what does public String replaceAll(string replace) do? (a) Replace all characters that matches pattern with a ... Expressions of Java Select the correct answer from above options...
asked Feb 24, 2022 in Education by JackTerrance
0 votes
    Which of the following is not a class of java.util.regex? (a) Pattern class (b) matcher class (c ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
    Basically i have a java String which i want to restrict all the characters other than this regex code ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Jun 18, 2022 in Education by JackTerrance
...