I found a script using the following syntax:
var variable3 = (Math.abs(variable1)>Math.abs(variable2)) ? variable1 : variable2;
As far, as I get it, that seems to compare if variable1
is bigger than variable2
. Then output, if yes, variable1
, otherwise variable2
?
I couldn't find any description and this seems to be something handy, could someone explain it?
THX!