foo.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
include<cstdio> include<cstring> include<algorithm>
^
foo.c:4:11: error: variably modified 's' at file scope
int Ans,n,s[N],p[N*2];
^
foo.c:4:16: error: variably modified 'p' at file scope
int Ans,n,s[N],p[N*2];
^
foo.c: In function 'main':
foo.c:6:1: warning: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
scanf("%d",&n);
^
foo.c:6:1: warning: incompatible implicit declaration of built-in function 'scanf' [enabled by default]
foo.c:12:1: warning: implicit declaration of function 'memset' [-Wimplicit-function-declaration]
memset(p,-1,sizeof(p));
^
foo.c:12:1: warning: incompatible implicit declaration of built-in function 'memset' [enabled by default]
foo.c:15:1: warning: implicit declaration of function 'max' [-Wimplicit-function-declaration]
Ans = max(Ans,i-p[s[i]+n]);
^
foo.c:20:1: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
printf("%d\n",Ans);
^
foo.c:20:1: warning: incompatible implicit declaration of built-in function 'printf' [enabled by default]