Submission
Status:
[PPPPPPPPPP]
Subtask/Task Score:
{100/100}
Score: 100
User: zibozzz_23
Problemset: นักบินอวกาศ
Language: cpp
Time: 0.004 second
Submitted On: 2026-10-14 01:08:33
#include <bits/stdc++.h>
using namespace std;
#define ll long long
int main(){
ios_base::sync_with_stdio(false);
cin.tie(nullptr);
ll n;
cin >> n;
ll rest = 4; ll ans = 0;
for(int i = 1; i <= n; ++i){
ans += rest;
rest += 6;
}
cout << ans << "\n";
}