diff --git a/AcWing/720/720.cpp b/AcWing/720/720.cpp new file mode 100644 index 00000000..84a40f48 --- /dev/null +++ b/AcWing/720/720.cpp @@ -0,0 +1,19 @@ +#include + +using namespace std; + +int a, n, ans; + +int main() { + cin >> a; + + while (cin >> n, n <= 0) {} + + for (int i = 0; i < n; i++) { + ans += i + a; + } + + cout << ans << endl; + + return 0; +}