The following code is a part of my user defined function in c
void genprime(long int m,long int n)
{
long int j,k,p[10000]={0},c,c1,c2,r;
int flag=0;
}
The function contains the logic to generate primes.I declared all variables type as long int as it was needed for high range.I am getting abnormal program termination message on execution.And when I declare all as int it is printing values but only for a specific range.Please help so that this can be resolved.Thanks in advance