#include<stdio.h>
int main()
{
int anik[] = {5,10,15,20,25,30,35,40,45,50,55,60,65,70,75,80,85,90,95,100};
int rob = -1, i, n;
printf("Enter any number : ");
scanf("%d", &n);
for(i=0; i<20; i++)
{
if(n == anik[i])
{
rob = i + 1;
break;
}
}
if(rob == -1)
{
printf("%d is not Found", n);
}
else
{
printf("%d is found in this Array at %d Position", anik[i], rob);
}
return 0;
}
int main()
{
int anik[] = {5,10,15,20,25,30,35,40,45,50,55,60,65,70,75,80,85,90,95,100};
int rob = -1, i, n;
printf("Enter any number : ");
scanf("%d", &n);
for(i=0; i<20; i++)
{
if(n == anik[i])
{
rob = i + 1;
break;
}
}
if(rob == -1)
{
printf("%d is not Found", n);
}
else
{
printf("%d is found in this Array at %d Position", anik[i], rob);
}
return 0;
}
Comments
Post a Comment