Register|Login

Have a question? Click here to ask the community.

Quiz 10 – Operators

| In: PHP Quizzes | 24,521 views

*You are currently not logged in and your quiz score will not be recorded. Please login or register if you would like to submit your quiz score.

Directions: Answer all questions. Any questions skipped will be scored as wrong answers. Good Luck! :)

1. If the variable $x = 10; , what will $x equal if it is incremented, that is, if I write $x++; what value will $x contain after it has been incremented?

9
10
11
12

2. The following example $a -= $b; is the same as?

$b = $a – $b;
$a = $a – $b;
$a = $b – $a;
$b = $b – $a;

3. The following comparison condition would return TRUE or FALSE:

(4 <> 7)

TRUE
FALSE

4. The logical operator && stands for?

OR
AND
NOT

5. The logical operator ! stands for?

OR
AND
NOT

6. The logical operator || stands for?

OR
AND
NOT

7. The following condition will return TRUE or FALSE:

(4 >= 4 && 8 < 1)

TRUE
FALSE


8. The following condition will return TRUE or FALSE:

(4 >= 4 || 8 < 1)

TRUE
FALSE


9. The following condition will return TRUE or FALSE:

!(4 >= 4 || 8 < 1)

TRUE
FALSE


10. The following condition will return TRUE or FALSE (This is a tough one for most beginners, but just think about it):

( (4 >= 4 && 8 < 1) || (44 == 33 || 5 > 3) )

TRUE
FALSE

Comment Form

You must be logged in to post a comment.

Users Online

Users Online: 5 Users

Most Users Ever Online: 91

Quiz Scores

Advertisments