Tell me the ternary conditional operator in php language?
Answer Posted / Naveen Sagar
The Ternary Conditional Operator (?:) is a shorthand if-else statement in PHP. It has the following syntax:
```php
(expression1) ? (expression2) : (expression3);
```
In this operator, `expression1` is tested. If it evaluates to `true`, then `expression2` is returned; otherwise, `expression3` is returned.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers