Language: C++

#pragma GCC optimize(2)
#include<bits/stdc++.h>
#define ll long long
#define maxn 1000005
#define inf 1e9
#define pb push_back
#define rep(i,a,b) for(int i=a;i<=b;i++)
#define per(i,a,b) for(int i=a;i>=b;i--)
using namespace std;

inline int read()
{
	int x=0,w=1; char c=getchar();
	while(c<'0'||c>'9') {if(c=='-') w=-1; c=getchar();}
	while(c<='9'&&c>='0') {x=(x<<1)+(x<<3)+c-'0'; c=getchar();}
	return w==1?x:-x;
}

ll a[maxn],b[maxn],p[maxn],n;

int main()
	n=read(); rep(i,1,n) p[i]=read();
	rep(i,1,n) a[i]=i*1000000,b[i]=(n-i+1)*1000000;
	rep(i,1,n) a[p[i]]+=i;
	rep(i,1,n) printf("%lld ",a[i]); puts("");
	rep(i,1,n) printf("%lld ",b[i]); puts("");
	return 0;
}

Compiler output:
a.cc:22:9: error: expected initializer before 'n'
   22 |         n=read(); rep(i,1,n) p[i]=read();
      |         ^
a.cc:7:20: error: expected unqualified-id before 'for'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                    ^~~
a.cc:22:19: note: in expansion of macro 'rep'
   22 |         n=read(); rep(i,1,n) p[i]=read();
      |                   ^~~
a.cc:22:23: error: 'i' does not name a type
   22 |         n=read(); rep(i,1,n) p[i]=read();
      |                       ^
a.cc:7:32: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                ^
a.cc:22:23: error: 'i' does not name a type
   22 |         n=read(); rep(i,1,n) p[i]=read();
      |                       ^
a.cc:7:37: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                     ^
a.cc:7:20: error: expected unqualified-id before 'for'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                    ^~~
a.cc:23:9: note: in expansion of macro 'rep'
   23 |         rep(i,1,n) a[i]=i*1000000,b[i]=(n-i+1)*1000000;
      |         ^~~
a.cc:23:13: error: 'i' does not name a type
   23 |         rep(i,1,n) a[i]=i*1000000,b[i]=(n-i+1)*1000000;
      |             ^
a.cc:7:32: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                ^
a.cc:23:13: error: 'i' does not name a type
   23 |         rep(i,1,n) a[i]=i*1000000,b[i]=(n-i+1)*1000000;
      |             ^
a.cc:7:37: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                     ^
a.cc:7:20: error: expected unqualified-id before 'for'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                    ^~~
a.cc:24:9: note: in expansion of macro 'rep'
   24 |         rep(i,1,n) a[p[i]]+=i;
      |         ^~~
a.cc:24:13: error: 'i' does not name a type
   24 |         rep(i,1,n) a[p[i]]+=i;
      |             ^
a.cc:7:32: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                ^
a.cc:24:13: error: 'i' does not name a type
   24 |         rep(i,1,n) a[p[i]]+=i;
      |             ^
a.cc:7:37: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                     ^
a.cc:7:20: error: expected unqualified-id before 'for'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                    ^~~
a.cc:25:9: note: in expansion of macro 'rep'
   25 |         rep(i,1,n) printf("%lld ",a[i]); puts("");
      |         ^~~
a.cc:25:13: error: 'i' does not name a type
   25 |         rep(i,1,n) printf("%lld ",a[i]); puts("");
      |             ^
a.cc:7:32: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                ^
a.cc:25:13: error: 'i' does not name a type
   25 |         rep(i,1,n) printf("%lld ",a[i]); puts("");
      |             ^
a.cc:7:37: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                     ^
a.cc:25:46: error: expected constructor, destructor, or type conversion before '(' token
   25 |         rep(i,1,n) printf("%lld ",a[i]); puts("");
      |                                              ^
a.cc:7:20: error: expected unqualified-id before 'for'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                    ^~~
a.cc:26:9: note: in expansion of macro 'rep'
   26 |         rep(i,1,n) printf("%lld ",b[i]); puts("");
      |         ^~~
a.cc:26:13: error: 'i' does not name a type
   26 |         rep(i,1,n) printf("%lld ",b[i]); puts("");
      |             ^
a.cc:7:32: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                ^
a.cc:26:13: error: 'i' does not name a type
   26 |         rep(i,1,n) printf("%lld ",b[i]); puts("");
      |             ^
a.cc:7:37: note: in definition of macro 'rep'
    7 | #define rep(i,a,b) for(int i=a;i<=b;i++)
      |                                     ^
a.cc:26:46: error: expected constructor, destructor, or type conversion before '(' token
   26 |         rep(i,1,n) printf("%lld ",b[i]); puts("");
      |                                              ^
a.cc:27:9: error: expected unqualified-id before 'return'
   27 |         return 0;
      |         ^~~~~~
a.cc:28:1: error: expected declaration before '}' token
   28 | }
      | ^