naive compilation error in code
<p>I have this code:</p>

<pre><code>#include&lt;iostream&gt;
#include&lt;algorithm&gt;

#define mod 1000000007

using namespace std;
unsigned long long int pow(int);
unsigned long long int binomialCoeff(int ,int );
int i,j;
int T[1000][1000];

int main()
{
    unsigned long long int t,k,n,ans;
    cin&gt;&gt;t;
    while(t--)
    {
        ans=0;
        cin&gt;&gt;n;
        int a[n];
        for(i=0;i&lt;n;i++)
        cin&gt;&gt;a[i];

        if(n%2==0)
            ans=(pow(n-1)-((binomialCoeff(n,n/2))/2))%mod;
        else
            ans=pow(n-1)%mod;

        printf("%lld\n",ans);
    }

    system("pause");
}

unsigned long long int binomialCoeff(int na,int rb)
{

    for(i=0;i&lt;na-rb+1;i++)
        **T[i,0]=1;**

    for(i=0;i&lt;rb+1;i++)
        **T[i,i]=1;**

    for(j=1;j&lt;rb+1;j++)
    {           
        for(i=j+1;i&lt;na-rb+j+1;i++)
            **T[i,j]=T[i-1,j-1]+T[i-1,j];**
    }
    return (T[na,rb]);
}


unsigned long long int pow(int n)
{
    int k;

    if(n==0)
        return 1;
    else if(n%2==0)
        {k=pow(n/2);return ((k%mod)*(k%mod))%mod;}
    else
        {k=pow(n/2);return ((((k%mod)*(k%mod))%mod)*2)%mod;}
}
</code></pre>

<p>I have this algorithm: </p>

<pre><code>2^(n-1) - ((1+(-1)^n)/4)*binomial(n, n/2)
</code></pre>

<p>...<a href="http://www.codechef.com/FEB13/problems/LECARDS" rel="nofollow">for this question</a>. </p>

<p>But in my compiler I am getting compilation errors:</p>

<pre><code>In function `long long unsigned int binomialCoeff(int, int)': 
   incompatible types in assignment of `int' to `int[1000]' 
   invalid operands of types `int[1000]' and `int[1000]' to binary `operator+' 
   invalid conversion from `int*' to `long long unsigned int' 
</code></pre>
