P2393 yyy loves Maths II
long double
比如保留5位小数
*1000000都变成整数
最后再/1000000避免精度误差
scanf("%Lf",&x);
printf("%.Lf",x);
#include<iostream>
#include<cstdio>
#include<queue>
#include<algorithm>
#include<cmath>
#include<ctime>
#include<cstring>
#define inf 2147483647
#define For(i,a,b) for(register int i=a;i<=b;i++)
#define p(a) putchar(a)
#define g() getchar()
//by war
//2017.10.21
using namespace std;
long double sum,x,t=; void in(int &x)
{
int y=;
char c=g();x=;
while(c<''||c>'')
{
if(c=='-')
y=-;
c=g();
}
while(c<=''&&c>='')x=x*+c-'',c=g();
x*=y;
}
void o(int x)
{
if(x<)
{
p('-');
x=-x;
}
if(x>)o(x/);
p(x%+'');
}
int main()
{
// freopen("t.in","r",stdin);
// freopen("t.out","w",stdout);
while(scanf("%LF",&x)!=EOF)
sum+=x*t;
printf("%.5LF",sum/t);
return ;
}