My Report

PHP Object Test – 3


Correct Answer: 2 points | Wrong: -1 point
Grades: A* (100% score) | A (80%-99%) | B (60%-80%) | C (40%-60%) | D (0%-40%)
advertisement

1. Which one of the following is a constant variable?

2. Which version of PHP introduced the static keyword?

3. How many of the following can be contained in constants?

i) boolean
ii) integer
iii) float
iv)  string

4. Which one of the following variable cannot be used inside a static method?

5. What does PDO stand for?

6. What will happen if you try to set a value to a constant once it has been declared?

7. In which of the following circumstance should you use a static reference to a non static method?

8. Which keyword is used to access a static method or property from within the same class(rather than from child)?

9. Which version of PHP allows you to define constant properties within a class?

10. Which keyword is used to declare a constant property?


 

Start practicing “1000 MCQs on PHP”, and once you are ready, you can take tests on all topics by attempting our “PHP Test Series”.

Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.