read a number & print all its devisors using c-program?
Answer Posted / vclingisetty@gmail.com
#include<stdio.h>
#include<conio.h>
void main()
{
int n,i;
clrscr();
printf("enter a number\n");
scanf("%d",&n);
for(i=1;i<=n;i++)
{
if(n%i==0)
printf("%d",i);
}
getch();
}
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What is pivot in c?
What is function prototype in c language?
which of the following is allowed in a "C" arithematic instruction a) [] b) {} c) () d) none of the above
Explain how do you generate random numbers in c?
Define Array of pointers.
What is fflush() function?
Is c high or low level?
How to implement a packet in C
Input is "rama loves rajesh and rajesh Loves rama also and rajesh wear gloves and bloves" To print output is count the numbers of times repeted the word love without case sensitive.
What is c language used for?
Is exit(status) truly equivalent to returning the same status from main?
When would you use a pointer to a function?
What is default value of global variable in c?
What are the types of data files?
What is wrong with this declaration?