What Will Be The Output Of The Following Php Codep Pre Langphp #268
What will be the output of the following PHP code?</p> <pre><code class="language-php" line="1"> <?php $line = "You like dogs. I hate dogs. We should marry."; $sen = preg_split('/\./', $line); print_r($sen); ?> </code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs107 PHP: Hypertext Preprocessor. It can also be found in gs gs107 Objects and Databases - PHP Preg Basics - Quiz No.1.
What will be the output of the following PHP code?
<?php $line = "You like dogs. I hate dogs. We should marry."; $sen = preg_split('/\./', $line); print_r($sen); ?>
You like dogs. I hate dogs. We should marry.
Array([0]=>You like dogs. I hate dogs. We should marry.)
Array([0]=>You like dogs. [1]=>I hate dogs. [2]=>We should marry.)
Error