Statistics for PHP Quiz for dummies #1

Click here to take the quiz!

General Stats

  • This quiz has been taken 14 times
  • The average score is 8 of 14

Answer Stats

QuestionAnswer% Correct
How do you declare a variable in PHP?$variable = 1;
100%
Which loops does PHP support?All of the above
92%
How do you declare a function in PHP?function myFunction(parameters) {body}
92%
How do you declare a array in PHP?$array = array();
83%
How do you define a class in PHP?class Fruits {}
75%
Select the correct code. (Can be more than 1)All of the above
67%
How do you import a file in PHP?include 'file.php';
67%
How do you read a file in PHP?readfile(filename);
58%
How do you access the headers, paths, and script locations.$_SERVER
50%
Which one of these is a datatype in PHP?All of the above
42%
What does PHP stand for?PHP: Hypertext Preprocessor
42%
How do you declare a constructor in PHP?function __construct() {}
33%
How do you call a private static variable inside a function of a class?self::$variable
33%
Which of the below is correct?Try/catch does not catch errors.
8%

Score Distribution

Percentile by Number Answered

Percent of People with Each Score

Your Score History

You have not taken this quiz