+ 2
Is there a standard function or in math functions that returns the sign of a float?
3 Answers
+ 7
This is why I love sololearn. I haven't had the need for anything like this so have never questioned it š
I learn from you all!
Short answer no.
See:
https://stackoverflow.com/questions/1903954/is-there-a-standard-sign-function-signum-sgn-in-c-c
oh btw, your post has been duplicated. Can you remove the duplicate. Thanks!
+ 4
Or did you by chance mean sine? As in sine, cosine, tangent? If so, include the math.h or cmath header file. This will give you access to those functions.
http://en.cppreference.com/w/cpp/numeric/math/sin
http://www.cplusplus.com/reference/cmath/sin/
+ 1
Thanks jay