Geeks Projects C
Every Program is here !!!
Pages
Home
Asp.Net
Java Programming
Web Programming
Friday, 19 September 2014
WAP to generate the divisor of number.
#include<conio.h>
#include<stdio.h>
void main()
{
clrscr();
int a;
printf("\nEnter valid no. to generate Divisor : ");
scanf("%d",&a);
printf("\n Divisors are ");
for(int i=1;i<=a/2;i++)
{
if(a%i==0)
{
printf("%d ",i);
}
}
getch();
}
No comments:
Post a Comment
Please write your doubts
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Please write your doubts