Which keyword can be used to fix the above error?
A. fix
B. join
C. use
D. namespace
Select an option to see the answer and solution.
Which one of the following statements is true for include_once() and require_once()?
A. Both are exactly the same
B. include_once is used for files where as require_once() is not
C. Both Handle the errors in the same way
D. Both do not handle the errors in the same way
Select an option to see the answer and solution.
Which one of the following statements is true for require() and require_once()?
A. They are functions
B. They are statements
C. They’ll not work if the () is not present
D. They can not be used to require files
Select an option to see the answer and solution.
Which function was introduced to help automate the inclusion of class files?
A. __load()
B. __preload()
C. __autoload()
D. __inload()
Select an option to see the answer and solution.
How many times can you define _______ autoload in a process?
A. once
B. twice
C. thrice
D. as many times as needed
Select an option to see the answer and solution.
Which one of the following functions will you use to check that the class exists before you work with it?
A. class_exist()
B. class_exists()
C. exist()
D. exists_class()
Select an option to see the answer and solution.
Which one of the following will you use to check the class of an object?
A. class()
B. _class()
C. class_check()
D. get_class()
Select an option to see the answer and solution.
PHP 4 did not support instanceof. Instead, which function did it provide?
A. is()
B. get_class()
C. is_a()
D. is_the()
Select an option to see the answer and solution.
You use the get_class_methods() function to return the names of all the methods in the class. Which function will you use to print it on the screen?
A. printf()
B. print_ar
C. print_r
D. echo
Select an option to see the answer and solution.
If you call a method and it doesn’t exist it’ll cause a problem. To check the method which function will you use?
A. _method()
B. methodexists()
C. is_callable()
D. is_method()
Select an option to see the answer and solution.
What will be the output if a protected method is given as argument to the function method_exist()?
A. Method does not exist
B. False
C. Error
D. True
Select an option to see the answer and solution.
Which one of the following function should I use to find the parent class of a class?
A. get_parent_class()
B. parent_class()
C. class_parent()
D. get_class_parent()
Select an option to see the answer and solution.
Which class accepts a class name or an object reference and returns an array of interface name?
A. class_implements()
B. is_subclass()
C. is_subclass_of()
D. class_interface()
Select an option to see the answer and solution.
Object-oriented code tries to minimize dependencies by moving responsibility for handling tasks away from _______ and toward the objects in the system.
A. server code
B. client code
C. machine code
D. procedural code
Select an option to see the answer and solution.
Placing a static method for generating _______ objects in the ________ class is convenient.
A. child parent
B. parent child
C. final static
D. static final
Select an option to see the answer and solution.
The extent to which proximate procedures are related to one another is known as.
A. Coupling
B. Balancing
C. Cohesion
D. Co-relation
Select an option to see the answer and solution.
______ occurs when discrete parts of a system’s code are tightly bound up with one another so that a change in one part necessitates changes in the others.
A. Loose Coupling
B. Tight Coupling
C. Co-relation
D. Balancing
Select an option to see the answer and solution.
________ code makes change easier because the impact of altering an implementation will be localized to the component being altered.
A. Orthogonal
B. Cohesion
C. Coupling
D. Balancing
Select an option to see the answer and solution.
Polymorphism is also known as______
A. switch
B. overact
C. encapsulation
D. class switching
Select an option to see the answer and solution.
Which one of the following is know as the key to object-oriented programming?
A. Polymorphism
B. Encapsulation
C. Data Abstraction
D. Orthogonality
Select an option to see the answer and solution.