• HOME
  • QUIZ
  • CONTACT US
EXAMIANS
  • COMPUTER
  • CURRENT AFFAIRS
  • ENGINEERING
    • Chemical Engineering
    • Civil Engineering
    • Computer Engineering
    • Electrical Engineering
    • Mechanical Engineering
  • ENGLISH GRAMMAR
  • GK
  • GUJARATI MCQ

PHP Arrays

PHP Arrays
What will be the output of the following PHP code ?
$a = array(12, 5, 2);
echo(array_product($a));

024
120
060
010

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
Assume you would like to sort an array in ascending order by value while preserving key associations. Which of the following PHP sorting functions would you use?

ksort()
usort()
asort()
sort()
krsort()

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
What functions count elements in an array?
1. count
2. Sizeof
3. Array_Count
4. Count_array

Option 2 and 4
Option 1 and 2
Option 3 and 4
Option 1 and 4

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
What will be the output of the following PHP code?
$fruits = array ("mango", "apple", "pear", "peach");
$fruits = array_flip($fruits);
echo ($fruits[0]);

peach
error
0
mango

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
Which in-built function will add a value to the end of an array?

inend_array()
array_unshift()
into_array()
array_push()

ANSWER DOWNLOAD EXAMIANS APP

PHP Arrays
Array values are keyed by ______ values (called indexed arrays) or using ______ values (called associative arrays). Of course, these key methods can be combined as well.

String, Boolean
Even number, string
Integer, string
Float, string
Positive number, negative number

ANSWER DOWNLOAD EXAMIANS APP
MORE MCQ ON PHP Arrays

DOWNLOAD APP

  • APPLE
    from app store
  • ANDROID
    from play store

SEARCH

LOGIN HERE


  • GOOGLE

FIND US

  • 1.70K
    FOLLOW US
  • EXAMIANSSTUDY FOR YOUR DREAMS.
  • SUPPORT :SUPPORT EMAIL ACCOUNT : examians@yahoo.com

OTHER WEBSITES

  • GUJARATI MCQ
  • ACCOUNTIANS

QUICK LINKS

  • HOME
  • QUIZ
  • PRIVACY POLICY
  • DISCLAIMER
  • TERMS & CONDITIONS
  • CONTACT US
↑