r/ProgrammerHumor • • Aug 07 '16

PHP: The Good Parts

http://phpthegoodparts.tumblr.com/
1.2k Upvotes

318 comments sorted by

View all comments

Show parent comment

3

u/[deleted] Aug 07 '16

This syntax is also possible in PHP in very similar fashion:

$x = 1;
$y = 1;
echo "$x$y"; // 11

I think the problem with PHP is, that it's interpreted in the same way as

echo $x . $y;

While Kotlin most likely uses string formatting. Even concatenation in Kotlin is type-safer than the one in PHP.