+ 2

Discuss: What is the Output and why?

Simple PHP Converting & Typecasting : Do you know the output without executing this Code? If so, explain why. Here we go: <?php $a = "a"; $b = "b"; $c = "c"; $a = $a + 1; $b = $b++; $c = ++$c; echo $a; echo $b; echo $c; ?>

27th Mar 2018, 1:44 PM
Jeff Block
Jeff Block - avatar
1 Odpowiedź
+ 1
I have to admit, I'm very surprised. Expected some different output. That's why I'm always double checking with echos a lot 😌
1st Jun 2018, 1:23 PM
Matthias
Matthias - avatar