Mansi and her series
Submissions: 828   Accuracy:

29.58%

  Difficulty: Easy   Marks: 2

Mansi is fond of solving mental ability questions. Today while solving some questions she came across a series which she was unable to solve. Help her to find the Nth term of the series.
N  Nth term
1  3
2  8
3  18
4  32
5  60
.
.
.
10  300

Input:
The first line of input contains an integer T denoting the number of test cases. For each test case, there is an integer N.

Output:
For each test case, print the Nth term of the series.

Constraints:
1 <= T <= 200
1 <= N <=6000

Example:
Input:
6
1
2
3
4
5
10
Output:
3
8
18
32
60
300

** For More Input/Output Examples Use 'Expected Output' option **

Author: kartikeyagoswami20


If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.



Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.

to report an issue on this page.