Regular Expressions In Ruby - Study Mode

[#16] What does the $ anchor represent in a regular expression in Ruby?
Correct Answer

(D) Matches the end of a line

[#17] Which metacharacter is used to specify character ranges in a regular expression in Ruby?
Correct Answer

(C) []

[#18] Which modifier is used to perform global matching in Ruby regular expressions?
Correct Answer

(B) g

[#19] What does the A anchor represent in a regular expression in Ruby?
Correct Answer

(C) Matches the start of a string

[#20] What is the purpose of the G anchor in a regular expression in Ruby?
Correct Answer

(D) Matches the point where the last match ended