File: test07.c

package info (click to toggle)
box64 0.3.8%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 24,880 kB
  • sloc: ansic: 373,273; python: 2,845; asm: 1,201; makefile: 267; sh: 112; cpp: 45
file content (20 lines) | stat: -rw-r--r-- 320 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
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;
}