I changed to
double List ()
{
double Div = N;
d = fmod(Div, N);
while (--Div > 0){
if( d == 0 )
Type: Posts; User: yusiye
I changed to
double List ()
{
double Div = N;
d = fmod(Div, N);
while (--Div > 0){
if( d == 0 )
How to use fmod inside a if function?
double List ()
{
double Div = N;
while (--Div > 0){
if((N % Div) == 0 )
printf("%.lf +", Div);
Thanks, Do you have any idea about the divisor,( not use modulo), That may help also.
It asks to get a number of its factors including 1(except the number itself). I want to write a new function for the LIST
Thanks a lot, Do you have any idea about the DIVISOR, the LIST function isn't really come from myself, I don't really understand it.:(
Your idea is really great, but the problem is it's too late, it's due this noon
The problem is from the divisor"List" function. I'm still debugging.
Sorry, I still don't get it. How to make it work?
I'm still work with my Prefect Number problem. But still have a little problem, the problem asks show all the divisor like this"1 + 2 + 3"
I tried the use "+" in the function, but the problem is i...
I tried the 1st. but it still goes to the negative numbers. :confused:
But i did call the function in the main. But what kind of a loop should I use in the prefect function.
can I use for instead of if?
I'm writing a problem to output all the prefect number which is less than 1million. But I have a little problem with hold all the numbers by using array. It only shows the first prefect number "6",...
#include <stdio.h>
#include <stdlib.h>
void List (int N);
int N = 0;
void main (void)
{
while (N < 40)
{
N++;
I don't need anyone to coding for me. i need idea of this program
The problems says "a program will find the sum of the proper divisors of a give number n. The proper divisors on n are the numbers less than n that divides it evenly, they do not include n itself." I...
The question asks to take the following list{12,31, 43, 23,25, 78, 200, 109, 345, 5, 188} into an integer array, and let the program find the smallest, median, and largest value and print them out....