Untitled

Anonymous
plain_text
08/26/2024 3:31 PM
312 B
18
Indexable
#include <iostream>
using namespace std;

int main() {
    unsigned long long a, b;
    cin >> a >> b;
    
    unsigned long long n = b - a + 1;

    unsigned long long tong = (a + b) * n / 2;
    
    cout << tong;
    return 0;
}
Editor is loading...
Leave a Comment