i am sorry somehow when i pressed the link i had given it went back to default code.
i now tried saving my code in that link.
It still isnβt working if i give long long to n and k.
Specifically it works if i give long long to only temp and counter
and not if i give it to n and k
thanks for your patience!!
this is the code
#include<bits/stdc++.h>
int main()
{
long long int n,k;
long long int temp,counter=0;
scanf("%d %d",&n,&k);
printf("%d %d",n,k);
while(n--)
{
scanf("%d",&temp);
printf("%d \n",temp);
if((temp%k)==0)
{ printf("reached");
counter++;
}
}
printf("%d\n",counter);
return 0;
}