11. Which modifier is used to perform multiline matching in Ruby regular expressions? A. m B. i C. x D. o Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option A No explanation is given for this question Let's Discuss on Board
12. What does the \b anchor represent in a regular expression in Ruby? A. Matches a non-word character B. Matches a non-word boundary C. Matches a word character D. Matches a word boundary Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option D No explanation is given for this question Let's Discuss on Board
13. What is the purpose of the * quantifier in a regular expression in Ruby? A. Matches one or more occurrences of the preceding character B. Matches one or zero occurrences of the preceding character C. Matches zero or more occurrences of the preceding character D. Matches exactly n occurrences of the preceding character Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option C No explanation is given for this question Let's Discuss on Board
14. What does the \w character class represent in a regular expression in Ruby? A. Matches any whitespace character B. Matches any word character C. Matches any digit character D. Matches any whitespace character Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option B No explanation is given for this question Let's Discuss on Board
15. Which method is used to extract all occurrences of a pattern in a string in Ruby? A. String#scan B. String#extract C. String#find_all D. String#match_all Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option A No explanation is given for this question Let's Discuss on Board
16. What does the $ anchor represent in a regular expression in Ruby? A. Matches the start of a string B. Matches the end of a string C. Matches the start of a line D. Matches the end of a line Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option D No explanation is given for this question Let's Discuss on Board
17. Which metacharacter is used to specify character ranges in a regular expression in Ruby? A. () B. {} C. [] D. <> Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option C No explanation is given for this question Let's Discuss on Board
18. Which modifier is used to perform global matching in Ruby regular expressions? A. x B. g C. o D. x Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option B No explanation is given for this question Let's Discuss on Board
19. What does the \A anchor represent in a regular expression in Ruby? A. Matches one or more occurrences of the previous character B. Matches any character except a newline C. Matches the start of a string D. Matches the end of a string Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option C No explanation is given for this question Let's Discuss on Board
20. What is the purpose of the \G anchor in a regular expression in Ruby? A. Matches the start of a string B. Matches the end of a string C. Matches any character except a newline D. Matches the point where the last match ended Answer & Solution Discuss in Board Save for Later Answer & Solution Answer: Option D No explanation is given for this question Let's Discuss on Board