
Quiz2

Quiz
•
Computers
•
University
•
Medium
Alok Sahoo
Used 4+ times
FREE Resource
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the regex pattern `[a-zA-Z]{3,}` match?
Exactly 3 letters
At least 3 letters (only lowercase)
At least 3 letters (both cases)
Exactly 3 uppercase letters
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which regex pattern matches a valid 10-digit mobile number at the end of a sentence?
'\d{10}$'
'\d{10}'
`^\d{10}`
`\d{10}\b
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will `re.findall(r'[+*/-]|\w+', '12 15+3 100-*')` return?
['12', '15', '+', '3', '100', '-', '*']
['12', '+', '3', '*']
['+', '-', '*']
['12', '15+3', '100-*']
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the regex pattern `(\w+) \1` do?
Matches two different words
Matches the same word repeated
Matches any character
Throws an error
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does `re.sub(r'(\w+) \1', r'\1', 'go go gone')` return?
'go gone'
'gone'
'go go gone'
'go gone gone'
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does `re.I` flag do?
Enables indentation
Ignores whitespace
Enables case-insensitive matching
Enables multi-line matching
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you match a literal dash `-` in a character class?
Put it at the start or end like `[-abc]`
. Escape it like `[a\-c]`
Both A and B
You can't match dash using character class
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Pemrograman 2: Regular Expressions (2/2)

Quiz
•
University
10 questions
Launchpad programming - day 7 morning (JS)

Quiz
•
University
15 questions
Java символы и строки

Quiz
•
University
20 questions
CpE111-Quiz4

Quiz
•
University
15 questions
Routing Table Quiz

Quiz
•
University
20 questions
Quiz Informatika Kelas VIII

Quiz
•
8th Grade - University
18 questions
Regular expressions

Quiz
•
University
10 questions
Python - Functions

Quiz
•
University
Popular Resources on Wayground
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
10 questions
Ice Breaker Trivia: Food from Around the World

Quiz
•
3rd - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
20 questions
ELA Advisory Review

Quiz
•
7th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Multiplication and Division Unknowns

Quiz
•
3rd Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
11 questions
NFL Football logos

Quiz
•
KG - Professional Dev...
20 questions
Definite and Indefinite Articles in Spanish (Avancemos)

Quiz
•
8th Grade - University
7 questions
Force and Motion

Interactive video
•
4th Grade - University
36 questions
Unit 5 Key Terms

Quiz
•
11th Grade - University
38 questions
Unit 6 Key Terms

Quiz
•
11th Grade - University
20 questions
La Hora

Quiz
•
9th Grade - University
7 questions
Cell Transport

Interactive video
•
11th Grade - University
7 questions
What Is Narrative Writing?

Interactive video
•
4th Grade - University