Go: package main

import (
        "fmt"
)

func main() {
        var num int
        for {
                _, err := fmt.Scan(&num)
                if err != nil {
                        break
                } else {
                        fmt.Printf("%d\n", (num*num+num+2)/2)
                }
        }
}

C++: #include<iostream>
#include<string>
#include<algorithm>
#include<map>
#include<set>
#include<utility>
#include<vector>
#include<cmath>
#include<cstdio>
#define loop(i,a,b) for(int i=a;i<b;i++) 
#define rep(i,a) loop(i,0,a)
#define rp(a) while(a--)
#define pb push_back
#define mp make_pair
#define it ::iterator
#define all(in) in.begin(),in.end()
const double PI=acos(-1);
const double EPS=1e-10;
using namespace std;
typedef long long ll;
typedef vector<int> vi;
int main(){
	int n;
	while(cin>>n){
		int sum=1;
		rep(i,n)sum+=i+1;
		cout<<sum<<endl;
	}
}

C++: #include <cstdio>
using namespace std;

int sygma(int n){
	if(n == 1) return 2;
	
	return 1 + n + sygma(n - 1);
}

int main(){
	int n;
	while(scanf("%d", &n) != EOF){
		printf("%d\n", (n > 1)? sygma(n) + 2 : 2);
	}
	
	return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
  int n;
  while(cin >>n){
    int ans = 2;
    for(int i=1; i<n; i++) ans+=i+1;
    cout <<ans<<endl;;
  }
  return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

int main()
{    
    int N;
    while (cin >> N) {
        cout << (N*N+N+2)/2 << endl;
    }
    return 0;
}

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

int main(){
    int n;
    while(cin>>n){
        cout<<2+(n-1)*(2+n)/2<<endl;
    }
    return 0;
}

C++: #include <cstdio>
#include <cstring>
#include <algorithm>
#include <string>
#include <cmath>
#include <stack>
#include <vector>
#include <map>
#include <set>
#include <iostream>
#include <climits>
#include <cfloat>


using namespace std;


int main()
{
	int area[10001];
	area[0] = 1;
	for (int i = 1; i <= 10000; ++i)
		area[i] = area[i-1] + i;

	int n;
	while (scanf("%d\n", &n) != EOF)
		printf("%d\n", area[n]);

	return 0;
}

C++: 
//Nayeem Shahriar Joy ,Applied Physics And Electronic Engineering , University of Rajshahi.

  #include <iostream>
  #include <cstdio>
  #include <algorithm>
  #include <cstring>

  #define MAX 105000

  using namespace std;

  int main()

  {
      int n;

      while(cin>>n)

      {
          cout<<((n*(n+1))/2)+1<<endl;
      }

      return 0;
  }

C++: /////////////////////////////////////////////////////////
//
//  c/temp.cpp file
//  Last Updated: 2018-10-23 ...Maybe
//
//    I hope you adding this code to the setting file
//    alias g++='g++ -std=c++1y -DDEBUG_LOCAL'
//
/////////////////////////////////////////////////////////

#include <bits/stdc++.h>

using namespace std;

#define fi first
#define se second
#define mp make_pair
#define pb push_back

//#define int long long

#define _overload3(_1,_2,_3,name,...) name
#define _REP(i,n) REAP(i,0,n)
#define REAP(i,a,b) for(int i=int(a);i<int(b);++i)
#define REP(...) _overload3(__VA_ARGS__,REAP,_REP,)(__VA_ARGS__)

#define _REPR(i,n) REAPR(i,n,0)
#define REAPR(i,a,b) for(int i=int(a-1);i>=int(b);--i)
#define REPR(...) _overload3(__VA_ARGS__,REAPR,_REPR,)(__VA_ARGS__)

#define ALL(a) a.begin(),a.end()
#define rALL(a) a.rbegin(),a.rend()

#define coutALL(a) {int loop_coutALL=0;for(auto e:a) cout<<(loop_coutALL++?" ":"")<<e; cout<<endl;}

#define coutYN(a) cout<<((a)?"YES":"NO")<<endl;
#define coutYn(a) cout<<((a)?"Yes":"No")<<endl;
#define coutyn(a) cout<<((a)?"yes":"no")<<endl;

#define pcnt __builtin_popcount
#define buli(x) __builtin_popcountll(x)

const int INF=1145141919;
//const long long INF=114514191911451419;
const int MOD=(int)1e9+7;
const double EPS=1e-12;
const int dx[]={1,0,-1,0},dy[]={0,1,0,-1};
//const int dx[]={-1,-1,-1,0,1,1,1,0},dy[]={-1,0,1,1,1,0,-1,-1};

using vi=vector<int>;
using vvi=vector<vi>;
using vs=vector<string>;

typedef pair<int,int> pii;
typedef pair<int,string> pis;
typedef pair<string,int> psi;
typedef pair<string,string> pss;

typedef long long ll;

template<typename T> istream &operator >> (istream &is, vector<T> &v){for(T &x:v) is>>x;return is;}
template<typename T> ostream &operator << (ostream &os, vector<T> &v){int i=0;for(T &x:v) os<<(i++?" ":"")<<x;return os;}

ll rev(ll n){ll x=0;for(;n>0;){x=x*10+n%10;n/=10;}return x;}

ll upper(ll n,ll m){return (n+m-1)/m;};
ll rounding(ll n){return (long double)n+0.5;};

bool inG(ll x,ll n){return 0<=x && 0<n;}
bool outG(ll x,ll n){return x<0 || n<=x;}

inline int qp(int a,ll b){if(!b)return 1;int ans=1;do{if(b&1)ans=1ll*ans*a;a=1ll*a*a;}while(b>>=1);return ans;}
inline int qp(int a,ll b,int mo){if(!b)return 1;int ans=1;do{if(b&1)ans=1ll*ans*a%mo;a=1ll*a*a%mo;}while(b>>=1);return ans;}

inline ll fac(ll k,ll n){ll a=1;for(int i=0;i<n;i++)a*=k--;return a;}
inline ll fac(ll k,ll n,int mo){ll a=1;for(int i=0;i<n;i++)a*=k--,a%=mo;return a;}

inline int dsum(ll n){int a=0;for(;n;n/=10)a+=n%10;return a;}

struct Arithmetic{Arithmetic(){cin.tie(0);ios::sync_with_stdio(0);cout<<fixed<<setprecision(20);}};

//#define DEBUG_LOCAL

#ifdef DEBUG_LOCAL
template<typename T> void deb(T a){cerr<<"deb: "<<a<<"です"<<endl;}
#define debl {cerr<<"debug: "<<__LINE__<<"行目だ"<<endl;}
void what_cr(){cout<<__GCC_ATOMIC_CHAR16_T_LOCK_FREE<<" ←？"<<endl;}
//ori_func S

//ori_func E
#else
template<typename T>void deb(T a){}
#define debl
void what_cr(){}void t_t(){}
#endif

signed main(){

  Arithmetic Exception;

  int ans[10001]={1};

  REP(i,1,10001) ans[i]=ans[i-1]+i;

  for(int n;cin>>n;cout<<ans[n]<<endl);

  return 0;

}

C++: #include<cstdio>
#include<cstdlib>
#include<cstring>
#include<cmath>
#include<cassert>
#include<iostream>
#include<sstream>
#include<string>
#include<vector>
#include<queue>
#include<set>
#include<map>
#include<utility>
#include<numeric>
#include<algorithm>
#include<bitset>
#include<complex>

using namespace std;

typedef long long Int;
typedef vector<int> vint;
typedef pair<int,int> pint;
#define mp make_pair

template<class T> void pv(T a, T b) { for (T i = a; i != b; ++i) cout << *i << " "; cout << endl; }
template<class T> void chmin(T &t, T f) { if (t > f) t = f; }
template<class T> void chmax(T &t, T f) { if (t < f) t = f; }
int in() { int x; scanf("%d", &x); return x; }
	
int main() {
	int n,res;
	for(;cin>>n;){
		int i;
		res=1;
		for(i=1;i<=n;i++){
			res+=i;
		}
		cout<<res<<endl;
	}
	return 0;
}

C++: #include <iostream>
using namespace std;

int main()
{
	int n;
	while(cin >> n){
		int area=0;
		if(n==0)
			area = 0;
		else if(n==1)
			area = 2;
		else if(n==2)
			area = 4;
		else if(n==3)
			area = 7;
		else{
			area = 7;
			for(int i=3;i<n;i++){
				area += i+1;
			}
		}
		cout << area << endl;
	}
	return 0;
}

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

int main(){
    int n,sum;
    while(cin>>n){
        sum=0;
        cin>>n;
        for(int i=1;i<=n;i++){
            sum=sum+i;
        }
        cout<<sum+1<<endl;
    }
	return 0;
}

C++: #include <cstdio>

int main(){
  int n;

  while(~scanf("%d",&n)){
    printf("%d\n",(n*n+n+2)/2);
  }
  return 0;
}

C++: #include <iostream>
using namespace std;

int main(){

  int a[10001] ;
  a[1] = 2;
  for(int i=2;i<=10000;i++) a[i] = a[i-1] + i;

  int n
  while(cin >> n){
  cout << a[n] << endl;
  }
  
  return 0;
}

C++: #include<iostream>
#include<iomanip>
#include<algorithm>
#include<bitset>
#include<cctype>
#include<cmath>
#include<cstdio>
#include<cstring>
#include<functional>
#include<limits>
#include<list>
#include<map>
#include<set>
#include<stack>
#include<string>
#include<sstream>
#include<queue>
#include<vector>
using namespace std;

#define MOD 1000000007
#define INF 0x3f3f3f3f
#define INFL 0x3f3f3f3f3f3f3f3fLL

int main() {
	for (int n; cin >> n;) {
		cout << 1 + n*(n + 1) / 2 << endl;
	}
	return 0;
}

C++: #include <iostream>
 
using namespace std;
 
int main() {
    int in;
    while(cin>>in){
        cout<<(in*(in+1)/2+1)<<endl;
    }
    return 0;

}