#include <iostream> using namespace std; int sum(int a, int b) { int res = 0; for(int i = a; i <= b; i++) res += i; return res; } int main() { int a, b; cin >> a >> b; cout << sum(a, b); }