Hi all,
I am probably missing something basic, but I cannot directly solve it by myself.
My question is about a function to return the sign of a given number, e.g.:
sign(-42) should return -1, sign(42) should return 1.
I cannot find such a fuction in the p5.js reference.
Of course I could devide the number by its absolute value, and build a fuction on my own, but I was just wondering why such basic function is not included in p5.js.
Thanks for a hint and best regards!