PHP Quiz

Answer 10 questions and see how you score!

1. Which function converts special characters to HTML entities?

2. Which function returns all defined constants?

3. What is the output of: echo 10 <=> 20;

4. What is the output of: echo strlen("Hello World");

5. How do you declare an array with keys in PHP?

6. Which of these is a correct way to create an array in PHP?

7. Which function outputs data and returns 1?

8. Which function reads a file into a string?

9. Which operator is used for spaceship comparison?

10. Which function converts an array to a string?