PHP Functions & Arrays Quiz – Immediate Feedback

1. A_________is a block of code that performs a specific task.

2. Pre-defined functions are also called _________.

3. Which one of the following is the right way of defining a function in PHP?

4. A user-defined function in PHP starts with the keyword _________.

5. Which of the following is a correct way to call a function in PHP?

6. What is an array in PHP?

7. How many types of arrays are there in PHP?

8. What is the index of the first element in an indexed array in PHP?

9. What is the index of the third element in an indexed array in PHP with 5 elements?

10. How do you create an indexed array in PHP?

11. How do you access the elements of an indexed array in PHP?

Score: 0 / 11