PHP MCQ Questions and Answers

Practice Mode
Showing 10 of 130 questions
Q1
Trace the odd data type
  • A floats
  • B integer
  • C doubles
  • D Real number
Answer: Option B
Q2
Which of the folowing are valid float values?
  • A 4.5678
  • B 4.0
  • C 7e4
  • D All of above
Answer: Option D
Q3
In php string data are
  • A delimited by single quote
  • B delimited by double quote
  • C delimited by <<< identifier
  • D All of above
Answer: Option D
Q4
Which of the following delimiting method is known as string Interpolation
  • A delimited by single quote
  • B delimited by double quote
  • C delimited by <<< identifier
  • D All of above
Answer: Option C
Q5
Which datatypes are treaded as arrays
  • A Integer
  • B Float
  • C String
  • D Booleans
Answer: Option C
Q6
Which of following are compound data type?
  • A Array
  • B Objects
  • C Both
  • D None
Answer: Option C
Q7
Casting operator introduced in PHP 6 is
  • A (array)
  • B (int64)
  • C (real) or (double) or (float)
  • D (object)
Answer: Option C
Q8
When defining identifier in PHP you should remember that
  • A Identifier are case sensitive. So $result is different than $ result
  • B Identifiers can be any length
  • C Both of above
  • D None of above
Answer: Option C
Q9
Identify the invalid identifier
  • A my-function
  • B size
  • C –some word
  • D This&that
Answer: Option D
Q10
&nbsp;Which of folowiing variable assignment is 'by value' assignment in PHP
  • A $value1= $value?
  • B $value1= & $value?
  • C $value1= & $value?
  • D None
Answer: Option A
Questions and Answers for Competitive Exams Various Entrance Test