Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1: The regular expression String regex = \"[xy]\"; matches (choose the best answ

ID: 3632149 • Letter: 1

Question

1: The regular expression
String regex = "[xy]";

matches (choose the best answer):

A. "x"
B. "y"
C. both A and B
D. neither A nor B

2: The regular expression
String regex = "[A-Z]*";
matches (choose the best answer):

A. any lowercase English letter
B. zero or more uppercase English letters
C. a single uppercase English letter
D. none of the above

3: Give a regular expression that matches every string ending with a letter.

4: Give a regular expression that matches lowercase hypenated English words; for example:
b-spline
twentieth-century
lily-of-the-valley

Explanation / Answer

1)C.both A and B
2)C.single uppercase english letter
3)Expression = *[A-Za-z]

4)expression = *-*

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote