//To print no. till limit, except those that are divisible by 8
#include<stdio.h>
#include<conio.h>
void main()
{
int n,i;
clrscr();
printf("Ener a limit");
scanf("%d",&n);
for(i=1;i<=n;i++)
if(i%8!=0)
printf("\n%d",i);
else
continue;
getch();
}
Hope you liked my posts, give comments if you have any doubts.. :)#include<stdio.h>
#include<conio.h>
void main()
{
int n,i;
clrscr();
printf("Ener a limit");
scanf("%d",&n);
for(i=1;i<=n;i++)
if(i%8!=0)
printf("\n%d",i);
else
continue;
getch();
}
Categories:
c program
0 comments:
Post a Comment