Factor Program in C language:- Q)Write a program in c language to enter a value and print factor of this number/value . Note:-You can a...
Factor Program in C language:-
Q)Write a program in c language to enter a value and print factor of this number/value.
Note:-You can also create this program in java,c#,c++(c plus plus) etc. with the same logic.
Q)Write a program in c language to enter a value and print factor of this number/value.
Note:-You can also create this program in java,c#,c++(c plus plus) etc. with the same logic.
P:#include<stdio.h>
void main()
{
int i,x;
printf("enter no.");
scanf("%d",&x);
for(i=0;i<=x;i++)
{
if(n%i==0)
printf("%d",i);
}
getch();
}
If you have any query then leave your comments and don't forgot to follow me on Google+,Facebook,Twitter.
COMMENTS