| Snaprecruit.com

| Snaprecruit.com

Interview question based on skill :

Take as many assements as you can to improve your validate your skill rating

Total Questions: 20

1. Which one of the following methods in the exception class, is used to get a nested exception object?

Correct Answer is : 1

2. Which one of the following keyword is used in conjunction with an Exception object?

Correct Answer is : 64

3. Which keyword is used to put a stop on inheritance?

Correct Answer is : performance_schema

4. PHP provides built-in interceptor methods, which can intercept messages sent to undefined methods and properties. This is also known as _________

Correct Answer is : any of the two

5. Which one of the following method is invoked when a value is assigned to an undefined property?

Correct Answer is : FALSE

6. Which one of the following method is invoked when an undefined method is called by client code?

Correct Answer is : –force

7. Which method introduced in PHP 5, is invoked just before an object is garbage collected?

Correct Answer is : more than 1

8. Which one of the following statements is true ? class CopyMe {}$first = new CopyMe();$second = $first;

Correct Answer is : CHARSET

9. Which keyword must be added before $first variable on the third line of the above question to make $second and $first as distinct objects in PHP 5?

Correct Answer is : USE

10. What will be output of following code ? class StringThing {}$st = new StringThing();print $st; Before the version PHP 5.2

Correct Answer is : big_tables

11. What will be the output of the following PHP code class Person { function getName() { return "Bob"; } function getAge() { return 44; } function __toString() { $desc = $this->getName(); $desc .= " (age ".$this->getAge().")"; return $desc; }}$person = new Person();print $person;

Correct Answer is : string

12. __clone() is run on the ___ object.

Correct Answer is : TRUE

13. Which method is invoked when an undefined property is accessed ?

Correct Answer is : INSTR()

14. What will be the output of the following PHP code? class Checkout { final function totalize() { // calculate bill } } class IllegalCheckout extends Checkout { final function totalize() { // change bill calculation }}

Correct Answer is : CGI.pm

15. Object-oriented code tries to minimize dependencies by moving responsibility for handling tasks away from ___ and toward the objects in the system.

Correct Answer is : Common Gateway Interface

16. Placing a static method for generating ___ objects in the ___ class is convenient.

Correct Answer is : use CGI

17. The extent to which proximate procedures are related to one another is known as…

Correct Answer is : #!

18. ______ 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.

Correct Answer is : database interface

19. ________ code makes change easier because the impact of altering an implementation will be localized to the component being altered.

Correct Answer is : /usr/bin/perl

20. Polymorphism is also known as______

Correct Answer is : CREATE TABLE name;