write an interactive program to generate the divisors of a
given integer.
Answer Posted / neo
#include <stdio.h>
void div(int n){
int i=2;
while(n%i!=0 && i!=n){
i++;
}
printf("%d ",i);
if(i!=n){
div(n/i);
}
}
main(){
int i;
printf("Enter number:");scanf("%d",&i);
printf("1 ");
div(i);
}
| Is This Answer Correct ? | 25 Yes | 11 No |
Post New Answer View All Answers
What is boolean in c?
What is pointer & why it is used?
What is meant by high-order and low-order bytes?
I completed my B.tech (IT). Actually I want to develop virtual object that which will change software technology in the future. To develop virtual object what course I have to take. can I any professor to help me.
Explain how do you list a file’s date and time?
What are pointers in C? Give an example where to illustrate their significance.
What are the differences between new and malloc in C?
In c programming, explain how do you insert quote characters (? And ?) Into the output screen?
a sequence of bytes with one to one corrspondence to those in the external device a) sequential addressing b) address c) byte code d) none
What is nested structure?
What is void c?
Which of these functions is safer to use : fgets(), gets()? Why?
write a program in c language to print your bio-data on the screen by using functions.
Write a program of advanced Fibonacci series.
What is the difference between volatile and const volatile?