
String regex Quiz
Authored by PHIL WILLIAMS
Computers
12th Grade
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
9 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the character class [a-z] represent in regex?
Any lowercase letter from a to z
Any number from 1 to 26
Any uppercase letter from A to Z
Any special character from a to z
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which quantifier in regex matches 0 or 1 occurrence of the preceding element?
{}
+
?
*
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Explain the use of grouping in regex with an example.
Grouping in regex is used to remove special characters from a pattern.
Grouping in regex is used to apply quantifiers to multiple characters, capture subpatterns, or create alternation. For example, (ab)+ will match one or more occurrences of 'ab'.
Grouping in regex is used to change the order of characters in a pattern.
Grouping in regex is used to match any character in a pattern.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of using the character class [0-9] in regex?
To match any single digit from 1 to 9
To match any special character
To match any single letter from a to z
To match any single digit from 0 to 9.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which quantifier in regex matches 0 or more occurrences of the preceding element?
?
+
!
*
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How can you use grouping to capture a specific part of a string in regex?
By using curly braces {} to create a capturing group
By using parentheses () to create a capturing group
By using angle brackets <> to create a capturing group
By using square brackets [] to create a capturing group
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Explain the difference between the character classes [A-Z] and [a-z] in regex.
[A-Z] matches uppercase letters and [a-z] matches lowercase letters.
[A-Z] matches lowercase letters and [a-z] matches uppercase letters.
[A-Z] matches numbers and [a-z] matches special characters.
[A-Z] matches vowels and [a-z] matches consonants.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
Google Apps
Quiz
•
10th Grade - Professi...
10 questions
PUNCTUATION SPACING RULES
Quiz
•
9th - 12th Grade
10 questions
COMPUTER PROGRAMMING Q2_FLOWCHART (2 points each)
Quiz
•
11th - 12th Grade
10 questions
Explorando Tinkercad en Secundaria
Quiz
•
7th Grade - University
10 questions
INTRODUCCION A LA PROGRAMACION
Quiz
•
6th Grade - University
10 questions
SHORTCUT PADA KEYBOARD
Quiz
•
10th - 12th Grade
11 questions
Threats to Data
Quiz
•
9th - 12th Grade
10 questions
Control y Robótica
Quiz
•
12th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade