✏️ Explanatory Question

Given the value of a variable, write a statement, without using if construct, which will produce the absolute value of the variable.

👁 17 Views
📘 Detailed Answer
🟢 Easy
No previous question
No next question
💡

Answer with Explanation

x = x < 0 ? -x : x ;

No previous question
No next question