Submission

Status:

[PPPPPPPPPP]

Subtask/Task Score:

{100/100}

Score: 100

User: Darleneee93

Problemset: นักบินอวกาศ

Language: cpp

Time: 0.004 second

Submitted On: 2026-10-15 11:49:40

#include <bits/stdc++.h>
using namespace std;

#define ll long long
#define float double
#define el << '\n'

int main(){
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    int n;
    cin >>n;
    int a=0;
    int b =4;

    for(int i=0;i<n;i++){
        a +=b;
        b +=6;
    }

    cout << a;
}