Home

What will be the output of the following PHP code?
 <?php  $age = array(Peter=>35, Ben=>37, Joe=>43);
print_r(array_change_key_case($age, CASE_UPPER));
?>

A.

Array ( [Peter] => 35 [Ben] => 37 [Joe] => 43 )

B.

Array ( [peter] => 35 [ben] => 37 [joe] => 43 )

C.

Array ( [PETER] => 35 [BEN] => 37 [JOE] => 43 )

D.

Array ( [PeTeR] => 35 [BeN] => 37 [Joe] => 43 )

Please do not use chat terms. Example: avoid using "grt" instead of "great".

You can do it
  1. What will be the output of the following PHP code ? <?php $color1 = red;$color2 = 1;$color3 = greyecho…
  2. What will be the output of the following PHP code ? <?php class myObject { }define('myObject::CONSTANT',…
  3. What will be the output of the following PHP code? <?php $age = array(Peter=>35, Ben=>37, Joe=>43);print_r(array_change_key_case($age,…
  4. What is the default number of seconds that cached session pages are made available before the new pages…
  5. What will be the output of the following PHP code? <?php $a = array(A, Cat, Dog, A, Dog);print_r(array_count_values($a));?>…
  6. What will be the output of the following code?<?php $foo = 'Bob'; $bar = &$foo; $bar…
  7. What will be the output of the following PHP code ? <?php $i = 0;while (++$i && --$i){ print $i;}…
  8. What will be the output of the following PHP code ? <?php define('GOOD_OCTAL', 0700);define('BAD_OCTAL',…
  9. What will be the output of the following PHP code ? <?php define(__LINE__, PHP is a scripting language);echo…
  10. What will be the output of the following PHP code ? <?php $color1 = red;$color2 = green;echo $color1…
  11. What will be the output of the following PHP code ? <?php $i = 5;while (--$i > 0 && ++$i){ print…
  12. Which function displays the web pages most recent modification date?
  13. PHP files have a default file extension of..
  14. Which one of the following function is used to start a session?
  15. What is the default time(in seconds) for which session data is considered valid?
  16. If session.use_cookie is set to 0, this results in use of..
  17. What will be the output of the following PHP code ? <?php $i = 0;while(++$i || --$i){ print $i;}…
  18. What will be the output of the following PHP code? If say date is 22/06/2013. <?php printf( date(t)…
  19. What will be the output of the following PHP code ? <?php $color1 = red;$color2 = red;echo $color1…
  20. What will be the output of the following code? If say date is 22/06/2013. <?php echo Today is .date(F…
  21. What will be the output of the following PHP code ? <?php define(NEW_GOOD_NAME_CONSTANT, I have a…
  22. What will be the output of the following PHP code ? <?php $color = red;$color = green;echo $color;?>…
  23. If the format is F then which one of the following will be returned?
  24. What does PHP stand for?i) Personal Home Pageii) Hypertext Preprocessoriii) Pretext Hypertext Processoriv)…
  25. What will be the output of the following PHP code ? <?php class Constants{ define('MIN_VALUE', '0.0');define('MAX_VALUE',…
  26. Which of following variables can be assigned a value to it?i) $3helloii) $_helloiii) $thisiv) $This
  27. What will be the output of the following PHP code ? <?php $color1 = red;$color2 = green;echo $color1…
  28. What will be the output of the following PHP code? <?php $cars = array(Volvo, BMW, Toyota, Honda,…
  29. What will be the output of the following PHP code ? <?php define('IF', 42);echo IF: , IF;?>
  30. What will be the output of the following PHP code ? <?php define(GREETING, PHP is a scripting language);echo…