SyntaxFix
Write A Post
Hire A Developer
Questions
Can be easily achieved with a ternary operator.
$is_negative = $profitloss < 0 ? true : false;