Today mainly do some 1.5 in the summary and practice, sure enough to change the language thinking ... All kinds of uncomfortable ah ...
scanf all kinds of forgotten &, there are all kinds of forgotten return 0 ...
#include <stdio.h>#include<math.h>int main () { int a,b,c; Double Ave; scanf ("%d%d%d",&a,&b,&c); Ave= (a+b+c)/3; printf ("%.3lf", ave); return 0 ;}
Average
#include <stdio.h>#include<math.h>int main () { double f,c; scanf ("%lf",&f); c=5* (f-C)/9; printf ("%.3lf", c); return 0 ;}
Temperature
#include <stdio.h>#include<math.h>int main () { int n,s; scanf ("%d",&N); s= (1+n) *n/2; printf ("%d", s); return 0 ;}
sum
#include <stdio.h>#include<math.h>intMain () {intN; Doublem; Const DoublePi=4.0*atan (1.0); scanf ("%d",&N); M=(float) n/ the*Pi; printf ("%.3LF%.3LF", Sin (m), cos (m)); return 0;}
Sincos
#include <stdio.h>#include<math.h>int main () { double x1, Y1,x2,y2,d; scanf ("%lf%lf%lf%lf",&x1,&y1,&x2,&y2); D=sqrt ((x1-x2) * (X1-X2) + (y1-y2) * (y1-y2)); printf ("%.3lf", D); return 0 ;}
Distance
White Leather Chapter 1