0_0_20635456_31790.cpp: In function 'int main()':
0_0_20635456_31790.cpp:13:22: error: expression list treated as compound expression in initializer [-fpermissive]
scanf("%d",&n);
^
0_0_20635456_31790.cpp:13:22: error: invalid conversion from 'int*' to 'long int' [-fpermissive]
0_0_20635456_31790.cpp:15:25: error: 'a' was not declared in this scope
scanf("%d",&a[j]);
^
0_0_20635456_31790.cpp:15:29: error: 'scanf' cannot be used as a function
scanf("%d",&a[j]);
^
0_0_20635456_31790.cpp:16:18: error: 'a' was not declared in this scope
sort(a,a+n);
^
0_0_20635456_31790.cpp:18:18: error: 'ans' was not declared in this scope
{if(k!=1&&k!=0)ans[k]=gcd(a[0],a[1]);
^
0_0_20635456_31790.cpp:20:3: error: 'ans' was not declared in this scope
ans[k]=gcd(a[1],a[2]);
^
0_0_20635456_31790.cpp:24:3: error: 'ans' was not declared in this scope
ans[k]=gcd(ans[k],a[l]);
^
0_0_20635456_31790.cpp:27:16: error: 'ans' was not declared in this scope
if(k==0) max=ans[0];
^
0_0_20635456_31790.cpp:28:6: error: 'ans' was not declared in this scope
if(ans[k]>max)max=ans[k];
^
|