nerdexam
Zend

200-550 · Question #172

Which parts of the text are matched in the following regular expression? $text = <<<EOT The big bang bonged under the bung. EOT; preg_match_all('@b.n?g@', $text, $matches);

The correct answer is C. big bang bong bung. See the full explanation below for the reasoning.

Question

Which parts of the text are matched in the following regular expression? $text = <<<EOT The big bang bonged under the bung. EOT; preg_match_all('@b.n?g@', $text, $matches);

Options

  • Abang bong bung
  • Bbang bonged bung
  • Cbig bang bong bung
  • Dbig bang bung

How the community answered

(20 responses)
  • A
    5% (1)
  • B
    5% (1)
  • C
    80% (16)
  • D
    10% (2)

Community Discussion

No community discussion yet for this question.

Full 200-550 Practice