GET THE NO OF ELEMENTS AS Ã n
STORE THE ELEMENTS IN THE FORM OF ARRAYÃ a[10000]
DIVISORÃ d
#include<stdio.h>
#include<stdlib.h>
int main()
{
int
n,d,i,a[10000];
scanf("%d",&n);
for(i=0;i<n;i++)
{
scanf("%d",&a[i]);
}
scanf("%d",&d);
for(i=0;i<n;i++)
{
if(a[i]%d==0)
printf("%d ",a[i]);
}
}
input:6 //NO OF INPUTS
10 20 30 40 50 60
//GET THE ELEMENTS IN THE ARRAY
4 //DIVISOR
output:20 40 60