mirror of
https://github.com/ptitSeb/box86.git
synced 2024-11-27 03:44:40 +08:00
Added test07
This commit is contained in:
parent
23b48b68cc
commit
bb9b5d8dc8
1
tests/ref07.txt
Normal file
1
tests/ref07.txt
Normal file
@ -0,0 +1 @@
|
||||
0 is 0.000000, sin(pi/2) is 1.000000 and 3*1.5 is 4.500000.
|
BIN
tests/test07
Executable file
BIN
tests/test07
Executable file
Binary file not shown.
20
tests/test07.c
Normal file
20
tests/test07.c
Normal file
@ -0,0 +1,20 @@
|
||||
#include <math.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.14159265358979323846
|
||||
#endif
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
long double zero = 0.0;
|
||||
|
||||
double si = sin(M_PI / 2.0);
|
||||
|
||||
int a = 3;
|
||||
float b = 1.5;
|
||||
float mul = a * b;
|
||||
|
||||
printf("0 is %Lf, sin(pi/2) is %f and 3*1.5 is %f.\n", zero, si, mul);
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user