TIL

Mar 18, 2017 19:40

Ternary operator f() ? g() : h() is left associative in PHP (unlike any other C-like language).
Another fun fact about ?: its result can be an lvalue in C++: http://stackoverflow.com/questions/8535226/return-type-of-ternary-conditional-operator.

c++, php

Previous post Next post
Up