Add QNX hellosqrt example source file

The rootfs repo contains the hellosqrt program for QNX that is
dynamically linked against libm. The source file is added here.
This commit is contained in:
Daniel Moos
2021-07-26 20:08:48 +02:00
parent c2ba238249
commit 3df797bc55
+11
View File
@@ -0,0 +1,11 @@
#include <math.h>
#include <stdio.h>
int main(int argc, char **argv)
{
double a = atan(1.0);
double b = sin(a);
double c = 1.0 / b;
printf("hello, sqrt(2) = %lf\n", c);
return 0;
}