Computer Science, asked by thebeast1123N, 3 months ago

Re-write the following using Ternary Operator.

int z=0;

if(x>y)

z=x-y;

else

z=y-x;​

Answers

Answered by khushiagarwal27611
1

Answer:

int z = 0;

z= if(x>y) ? x-y: y-x

Similar questions