Cyber Monday 2024! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Zend Exam 200-710 Topic 8 Question 60 Discussion

Actual exam question for Zend's 200-710 exam
Question #: 60
Topic #: 8
[All 200-710 Questions]

What will the following code piece print?

echo strtr('Apples and bananas', 'ae', 'ea')

Show Suggested Answer Hide Answer
Suggested Answer: A

Contribute your Thoughts:

Chauncey
5 months ago
That makes sense. I guess 'C) Apples and bananas' is the correct answer.
upvoted 0 times
...
Geoffrey
6 months ago
Because the strtr function replaces characters in a string based on matching pairs, so 'ae' will be replaced with 'ea'.
upvoted 0 times
...
Isaiah
6 months ago
But why do you think that, Geoffrey?
upvoted 0 times
...
Geoffrey
6 months ago
I'm pretty sure it's going to be 'Apples and bananas'.
upvoted 0 times
...
Chauncey
6 months ago
I believe it will be 'Applas end benenes'.
upvoted 0 times
...
Isaiah
6 months ago
I think it will print 'Epplas end benenes'.
upvoted 0 times
...
Maynard
7 months ago
I believe the 'a' and 'e' in the arguments of strtr() function have been swapped, resulting in the letters in the string being replaced accordingly.
upvoted 0 times
...
Ma
7 months ago
But why do you think it is A and not B or C?
upvoted 0 times
...
Tamar
7 months ago
Actually, the correct answer is A) Applas end benenes.
upvoted 0 times
...
Maynard
7 months ago
I think it will be C) Apples and bananas.
upvoted 0 times
...
Ma
7 months ago
The answer is B) Epplas end benenes.
upvoted 0 times
...

Save Cancel
az-700  pass4success  az-104  200-301  200-201  cissp  350-401  350-201  350-501  350-601  350-801  350-901  az-720  az-305  pl-300  

Warning: Cannot modify header information - headers already sent by (output started at /pass.php:70) in /pass.php on line 77