This is working fine in my system and but it is showing runtime error.

#include<stdio.h>
int main(void)
{
unsigned int n,k,t;
int i,p=0;
scanf("%d %d",&n,&k);
for(i=0;i<n;i++)
{ scanf("%d",&t);
if(t%k==0)
{ p++;
}
}
printf("%d",p);
}

Correctly format your code on give a link. Also provide details about the question you are trying to solve.

One problem with your code is that there is no return statement. Add a return(0) statement before the last braces.

Hi deepika987,

Very first, please try pasting your code above in proper blocks or it’s always better to give the ideone link. The code is giving RTE because you haven’t added return 0; statement for main(). Add that and it’ll work.