Skip to content

Instantly share code, notes, and snippets.

@Titory0
Created January 17, 2023 12:55
Show Gist options
  • Save Titory0/6cd2f0ebd0693a34aaadbafb46a0dcaa to your computer and use it in GitHub Desktop.
Save Titory0/6cd2f0ebd0693a34aaadbafb46a0dcaa to your computer and use it in GitHub Desktop.
public static int ft_gauss(int a, int b)
{
int calcul=0;
if(a<b){
for(int i=a;i<b+1;i++)
{
calcul+=i;
}
if(calcul>=0)
{
return calcul;}}
return-1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment