how to use this || with ternary function in php code example Example: ternary operator in php <?php $marks=40; print ($marks>=40) ? "pass" : "Fail"; ?>