0_0_14688767_1582.cpp:5:33: error: 'ld pow [100010]' redeclared as different kind of symbol
int n,i,j,k=50,d[N];ld ans,pow[N];
^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/cmath:44:0,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:38,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
from 0_0_14688767_1582.cpp:2:
GCC4.9.2/x86_64-w64-mingw32/include/math.h:151:18: note: previous declaration 'double pow(double, double)'
double __cdecl pow(double _X,double _Y);
^
0_0_14688767_1582.cpp: In function 'int main()':
0_0_14688767_1582.cpp:7:13: error: assignment of function 'double pow(double, double)'
for(pow[0]=1,i=d[1]=1;i<=k;i++)pow[i]=pow[i-1]*2;
^
0_0_14688767_1582.cpp:7:13: error: cannot convert 'int' to 'double(double, double)' in assignment
0_0_14688767_1582.cpp:7:50: error: invalid operands of types 'double(double, double)' and 'int' to binary 'operator*'
for(pow[0]=1,i=d[1]=1;i<=k;i++)pow[i]=pow[i-1]*2;
^
0_0_14688767_1582.cpp:13:54: error: invalid operands of types 'double(double, double)' and 'int' to binary 'operator*'
for(i=n;i;i--)for(j=n;j>i;j--)ans+=pow[i-1]*d[i]*d[j]/(d[i]+d[j]);
^
0_0_14688767_1582.cpp:14:10: error: invalid operands of types 'ld {aka long double}' and 'double (*)(double, double)' to binary 'operator/'
ans/=pow[n]-n-1;
^
0_0_14688767_1582.cpp:14:10: error: in evaluation of 'operator/=(ld {aka long double}, double (*)(double, double))'
0_0_14688767_1582.cpp:16:81: error: invalid operands of types 'double' and 'double(double, double)' to binary 'operator/'
for(i=n;i>n-k;i--)for(j=n;j>i;j--)ans+=1.0*d[i]*d[j]/(d[i]+d[j])/pow[n-i+1];
^
|