read a number & print all its devisors using c-program?
Answer Posted / karna
//all devisors of a number
#include<stdio.h>
#include<conio.h>
void main()
{
int n,i;
printf("Enter the number");
scanf("%d",&n);
for(i=1;i<=n;i++)
{
if((n%i)==0)
{
printf("%d\n",i);
}
else;
}
getch();
}
| Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
What is the size of enum in c?
how can f be used for both float and double arguments in printf? Are not they different types?
Does * p ++ increment p or what it points to?
What is string constants?
How can I rethow can I return a sequence of random numbers which dont repeat at all?
What is the use of bit field?
What are the application of c?
What is the difference between constant pointer and constant variable?
What is the use of getchar functions?
What is oops c?
1) There is a singing competition for children going to be conducted at a local club. Parents have been asked to arrive at least an hour before and register their children’s names with the Program Manager. Whenever a participant registers, the Program Manager has to position the name of the person in a list in alphabet order. Write a program to help the Program Manager do this by placing the name in the right place each time the Program Manger enters a name. 2) the Event Manager has to send participants to the stage to perform in the order in which they registered. Write a program that will help the Event Manager know who to call to the stage to perform. The Logic should be in Data Structures
What is the process to generate random numbers in c programming language?
I need a help with a program: Write a C program that uses data input in determining the whole of points A and a whole of circles B. Find two points in A so that the line which passes through them, cut through the maximum number of circles.
What is the size of enum in bytes?
Explain the binary height balanced tree?