what are the various factor used for writing a C program? Give example.
Answers
Answered by
1
Answer:
=>include <stdio.h>
=>int num, i;
=>printf("Enter a positive integer: ");
=>scanf("%d", &num);
=>printf("Factors of %d are: ", num);
=>for (i = 1; i <= num; ++i) {
=>if (num % i == 0) {
=>printf("%d ", i);
Similar questions