My Program is running well and totally correct but it is considering wrong

// Program for calculating Factorials

#include <stdio.h>

int main(void) {
// your code goes here
int N, ar[220]={0}, i, count=0, insertVal;
ar[0] = 1;
scanf("%d", &N);
for(i=1; i<=N; i++){
int j=0, rem = 0, k = 2i;
do{
insertVal = rem + i
ar[j];
ar[j] = insertVal%10;
rem = insertVal/10;
j++;
}while(k–);
}
for(i=0; i<220; i++){
if(ar[220-i-1])
break;
}

for(count=i; count<220; count++)
	printf("%d", ar[220-count-1]);
return 0;

}

Please either format your code or (better!) link to your submission - the forum software has mangled it and it won’t compile! :slight_smile:

Also - what Problem are you trying to solve?

calculating factorial 1<=N<=100

But my program is working correctly in dev-CPP and giving expected output, but here it is considering as “Wrong Answer”