#include using namespace std; long sumOfGroup(long k) { // Return the sum of the elements of the k'th group. long temp,next,sum=0; if(k==1) return 1; else temp = (k*(k-1) +1); k+=1; next = (k*(k-1) +1); while(temp> k; long answer = sumOfGroup(k); cout << answer << endl; return 0; }