"> What will be the output of the following PHP code ?<?php$Student

Home » PHP » PHP Sorting Arrays » Question
  1. What will be the output of the following PHP code ?
    <?php
    $Student = array("Ajit", "Rahul", "Ats", "Aju");
    echo pos($Student);
    ?>
    1. Ajit
    2. Rahul
    3. Ats
    4. Aju
    5. None of these
Correct Option: A

The pos() function returns the value of the current element in an array, and since no operation has been done, the current element is the first element.



Your comments will be displayed only after manual approval.