Last active
July 13, 2016 17:52
-
-
Save dcci/7d403382af69ce9c66708c8fb37b150d to your computer and use it in GitHub Desktop.
Floating point is fun
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <math.h> | |
#include <stdio.h> | |
int main(void) { | |
// pow(x, 0.5) -> sqrt(x) | |
printf("%f %f\n", pow(-0.0, 0.5), sqrt(-0.0)); | |
return (0); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment