Advertisement
Josif_tepe

Untitled

Nov 11th, 2024
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.21 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     int N;
  6.     scanf("%d", &N);
  7.    
  8.     for(int i = 1; i <= N; i++) {
  9.         if(N % i == 0) {
  10.             printf("%d, ", i);
  11.         }
  12.     }
  13.    
  14.    
  15.     return 0;
  16. }
  17.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement