Hello everyone, I’m new to this programming world, I would like to know what I’m doing wrong with this problem -> DIVSUM - Divisor Summation
#include <stdio.h>
#include <stdlib.h>
int soma_div(int numero){
int aux = numero;
int soma = 0;
int cont = 0;
if(numero == 1){
soma = 0;
}
while(cont != numero){
if(aux != 0 && numero != aux && numero % aux == 0){
soma = aux + soma;
}
aux--;
cont++;
}
return soma;
}
int main(){
int resultado = 0;
int numero;
scanf("%d",&numero);
if(1 < numero && numero <= 500.000){
resultado = soma_div(numero);
printf("%d\n",resultado);
}
return 0;
}