MCQs>IT & Programming>Regular Expressions With PHP Test>Analyze the following code snippet that uses the preg_last_error() PHP Regular Expression method: < ?php preg_match('/(?:\D+|<\d+>)*[!?]/', 'foobar foobar foobar'); if (preg_last_error() == PREG_BACKTRACK_LIMIT_ERROR) { echo 'Backtrack limit was exhausted!'; } ?> What will be the output of the above code?
Regular Expressions With PHP Test MCQs
Analyze the following code snippet that uses the preg_last_error() PHP Regular Expression method:
<?php
preg_match('/(?:\D+|<\d+>)*[!?]/', 'foobar foobar foobar');
if (preg_last_error() == PREG_BACKTRACK_LIMIT_ERROR) {
echo 'Backtrack limit was exhausted!';
}
?>
What will be the output of the above code?
Answer
Correct Answer: Backtrack limit was exhausted!
Explanation:
Note: This Question is unanswered, help us to find answer for this one
Regular Expressions With PHP Test Skill Assessment