Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main(int argc, const char * argv[])
- {
- int a=0;
- scanf ("%d", &a);
- if (a==0) {
- printf("%d",0);
- }
- if (a<0){
- for (int i = a; i<= -a; i++) {
- if(i==0) continue;
- if (a%i==0){
- printf("%d",i);
- }
- }
- } else {
- for (int i = -a; i<=a; i++) {
- if(i==0) continue;
- if (a%i==0){
- printf("%d",i);
- }
- }
- }
- return 0;
- }v
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement