// NChooseThree.C
// enter N and output n(n+1)(n+2)/3

// Note: since one of n, n+1, n+2 must be divisible by
//   3, the result is an integer. Multiply first, to
//   avoid truncating divide

#include<iostream.h>

void main()
{

   int n ;
   cout << "Enter n: " ;
   cin >> n ;
   cout <<"The answer is " << (n*(n+1)*(n+2))/3 << endl ;
}

