class Solution { public: int getSum(int n) { typedef long long ll; ll s=(ll)n*(n+1)/2; return s; } };