For this Question: Given an integer N as an input, print a pattern as shown in sample.Input contains a single integer N

Constraints:-
1<=N<=15Print the patter for N.Sample Input:
3

Sample Output: 
3 3 3 3 3
3 2 2 2 3
3 2 1 2 3
3 2 2 2 3
3 3 3 3 3, I have written this Solution Code: #include <bits/stdc++.h>
using namespace std;

#define max 100

void print(int a[][max], int size)
{
for (int i = 0; i < size; i++) {
	for (int j = 0; j < size; j++) {
	cout << a[i][j]<<" ";
	}
	cout <<endl;
}
}

void innerPattern(int n) {
	
int size = 2 * n - 1;
int front = 0;
int back = size - 1;
int a[max][max];
while (n != 0)
{
	for (int i = front; i <= back; i++) {
	for (int j = front; j <= back; j++) {
		if (i == front || i == back ||
			j == front || j == back)
		a[i][j] = n;
	}
	}
	++front;
	--back;
	--n;
}
print(a, size);
}

int main()
{
	int n ;
	cin>>n;
	
	innerPattern(n);
	
return 0;
}



, In this Programming Language: C++, Now tell me if this Code is compilable or not?