MCQs > IT & Programming > PHP > Output of the code?

PHP MCQs

What will be the output of the following code?

<?php

$numbers=array();

$numbers[1] = 1;

$numbers[2] = 2;

$numbers[3] = 3;

$numbers[4] = 4;

$key=  array_search(3,$numbers);

unset($numbers[$key]);

print_r($numbers);

?>

Answer

Correct Answer: Array ( [1] => 1 [2] => 2 [4] => 4 )

Explanation:

Note: This Question is unanswered, help us to find answer for this one

PHP Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

PHP Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it