https://programmers.co.kr/learn/courses/30/lessons/12912
a와 b 사이에 속한 모든 정수의 합을 리턴하는 것이기에 반복문을 이용
제한 조건의 a, b가 같을 경우
a, b 둘중 어떤 것이 큰지
#include <stdio.h>
#include <stdbool.h>
#include <stdlib.h>
long long solution(int a, int b) {
long long answer = 0;
if(a == b) return a;
if(a>b){
for(int i=b; i<a+1; i++) answer+=i;
} else{
for(int i=a; i<b+1; i++) answer +=i;
}
return answer;
}