Question 1 of 25
Hints left: 3
Q1
What happens if a block is passed to a method that doesn't expect one in Ruby?
Q2
Which metacharacter is used to specify character ranges in a regular expression in Ruby?
Q3
What does the \A anchor represent in a regular expression in Ruby?
Q4
What is a block in Ruby?
Q5
How do you define a lambda in Ruby?
Q6
What does the \w character class represent in a regular expression in Ruby?
Q7
What is the difference between a block and a proc in Ruby?
Q8
Which metacharacter is used to specify the beginning of a line in a regular expression in Ruby?
Q9
How do you pass a proc as an argument to a method in Ruby?
Q10
How do you call a block in Ruby?
Q11
Which modifier is used to perform single-line matching in Ruby regular expressions?
Q12
Which metacharacter is used to specify grouping in a regular expression in Ruby?
Q13
What does the & operator do when used with a proc in Ruby?
Q14
What is a proc in Ruby?
Q15
How do you create a proc in Ruby?
Q16
What is the purpose of the \G anchor in a regular expression in Ruby?
Q17
What does the $ anchor represent in a regular expression in Ruby?
Q18
Which method is used to extract all occurrences of a pattern in a string in Ruby?
Q19
Which modifier is used to perform global matching in Ruby regular expressions?
Q20
What is the purpose of using blocks and procs in Ruby?
Q21
What is a lambda in Ruby?
Q22
What does the (?<=...) construct represent in a regular expression in Ruby?
Q23
Which method is used to split a string into substrings based on a regular expression in Ruby?
Q24
How do you define a block in Ruby?
Q25
What does the (?<!...) construct represent in a regular expression in Ruby?