For this Question: Given an index K, return the K-th row of <a href = "https://en.wikipedia.org/wiki/Pascal%27s_triangle">Pascal’s triangle</a>.
You must print the K-th row modulo 10<sup>9</sup> + 7.

<b>The rows of Pascal's triangle are conventionally enumerated starting with row K=0 at the top (the 0th row) </b>The only line of input contains the input K.

<b>Constraints:-</b>
0 &le; K &le; 3000
Print k-th row of Pascal's Triangle containing k+1 integers modulo 10^9+7.Sample Input :
3

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



signed main()
{
    int t,n;
    t=1;
    vector<vector<long long> > v(3002);
    for(int i=0; i<=3001; i++)
    {
        for (int j=0; j<=i; j++)
        {
            if (j==0 || j==i) v[i].push_back(1);
            else v[i].push_back((v[i-1][j]%mod + v[i-1][j-1]%mod)%mod);
        }
    }
    while (t--)
    {
        cin>>n;
        n=n+1;
        for (int i=0; i<v[n-1].size(); i++)  cout<<v[n-1][i]<<" ";
        cout<<"\n";
    }
	return 0;
}
, In this Programming Language: C++, Now tell me if this Code is compilable or not?