Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
lab6
//gcc 5.4.0 #include <stdio.h> #include <math.h> int main(void) { int x; scanf("%d",&x); float sin = x - (x*x*x)/(3*2*1) + (x*x*x*x*x)/(5*4*3*2*1) - (x*x*x*x*x*x*x)/(7*6*5*4*3*2*1); float cos = 1 - (x*x)/(2*1) + (x*x*x*x)/(4*3*2*1) - (x*x*x*x*x*x)/(6*5*4*3*2*1); float tan= sin/cos; float cot= cos/sin; printf("the result is %f\n ",sin); printf("the result is %f\n ", cos); printf("the result is %f\n ",tan); printf("the result is %f\n ",cot); return 0; }
run
|
edit
|
history
|
help
0
Présentation
day 3 integer manipulation
22nd HW Switchv1.0
Hello
String copy
sqrt function
la profe
Practice flipping the stars
Maze
++i vs i++