foo.cpp:9:1: error: 'define' does not name a type
define MAXn 100
^
foo.cpp:13:14: error: 'MAXn' was not declared in this scope
long long x1[MAXn+1],y1[MAXn+1];
^
foo.cpp:13:25: error: 'MAXn' was not declared in this scope
long long x1[MAXn+1],y1[MAXn+1];
^
foo.cpp:14:14: error: 'MAXn' was not declared in this scope
long long x2[MAXn+1],y2[MAXn+1];
^
foo.cpp:14:25: error: 'MAXn' was not declared in this scope
long long x2[MAXn+1],y2[MAXn+1];
^
foo.cpp:15:13: error: unable to find numeric literal operator 'operator"" MAXn'
long long x[2MAXn+1],y[2MAXn+1];
^
foo.cpp:15:24: error: unable to find numeric literal operator 'operator"" MAXn'
long long x[2MAXn+1],y[2MAXn+1];
^
foo.cpp: In function 'int main()':
foo.cpp:19:71: error: 'x1' was not declared in this scope
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k]) { ans+=S; break; } } printf("%I64d",ans); return 0; }
^
foo.cpp:19:78: error: 'y1' was not declared in this scope
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k]) { ans+=S; break; } } printf("%I64d",ans); return 0; }
^
foo.cpp:19:85: error: 'x2' was not declared in this scope
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k]) { ans+=S; break; } } printf("%I64d",ans); return 0; }
^
foo.cpp:19:92: error: 'y2' was not declared in this scope
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k]) { ans+=S; break; } } printf("%I64d",ans); return 0; }
^
foo.cpp:19:100: error: 'x' was not declared in this scope
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k]) { ans+=S; break; } } printf("%I64d",ans); return 0; }
^
foo.cpp:19:102: error: unable to find numeric literal operator 'operator"" i'
scanf("%d",&n); for(int i=1;i<=n;i++) { scanf("%I64d%I64d%I64d%I64d",&x1[i],&y1[i],&x2[i],&y2[i]); x[2i-1]=x1[i]; x[2i]=x2[i]; y[2i-1]=y1[i]; y[2i]=y2[i]; } sort(x+1,x+2n+1); sort(y+1,y+2n+1); for(int i=1;i<=2n-1;i++) for(int j=1;j<=2n-1;j++) { S=(x[i+1]-x[i])*(y[j+1]-y[j]); for(int k=1;k<=n;k++) if(x[i]>=x1[k]&&y[j]>=y1[k]&&x[i+1]<=x2[k]&&y[j+1]<=y2[k])