Advertisement
pranto_95

Factors

Aug 8th, 2015
214
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. /*find factors*/
  2. #include<stdio.h>
  3. int main(){
  4. int i,a,x;
  5.  
  6. scanf("%d",&x);
  7. for(i=1;i<=x;i++){
  8. if(x%i==0){
  9. printf("%d\n",i);
  10. }
  11. }
  12. return 0;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement