Skip to content

Instantly share code, notes, and snippets.

@kalinathalie
Created December 5, 2015 18:05
Show Gist options
  • Select an option

  • Save kalinathalie/86b9b1b7d62f808bdac9 to your computer and use it in GitHub Desktop.

Select an option

Save kalinathalie/86b9b1b7d62f808bdac9 to your computer and use it in GitHub Desktop.
wesley safadao
#include <stdio.h>
#include <math.h>
void wesley_safadao(){
int dia, mes, ano, safadeza, anjo, somatorio=0, i;
scanf("%d %d %d", &dia, &mes, &ano);
for(i=1;i<=mes;i++){
somatorio+=i;
}
safadeza = somatorio+(ano/100)*(50-dia);
anjo = 100-safadeza;
}
printf("Bem vindo a calculadora Wesley Safadão!\n Sua safadeza é %d\nSeu Anjo é %d\n", safadeza, anjo);
return 0;
}
int main(){
void wesley_safadao();
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment