SP15631 PLUS - On the Plus Side

Description

A man called Gerit Teeman was fascinated by the plus symbol and, to be honest, this symbol is actually quite interesting! Begin by drawing an one. This will be the center of the plus symbol. Above this center draw the number two, below three, to the left four and the the right five. If you then 'replace' the center (either up, down, left or right), do the same, but when a place is already filled you leave it untouched. To illustrate this we pick the place with the number two: Above it draw a two, the bottom is already filled so we leave it untouched, to the left we draw a four and the the right we draw a five. See the picture below: ![example](/content/zukow:plusex1.png "example 1") It is not hard to see that the sum of the first plus symbol is 15 (the first symbol only containing 1 is NOT a plus symbol). The sum of the second symbol is already more difficult, summing up to 26. Now here comes the catch: depending on which number you pick to expand on, the number on positions can change. If we would have picked five to expand on instead of two, we will get the following: ![example](/content/zukow:plusex2.png "example 2") As you can see the numbers differ from that of the first example. This time the sum is 25! On top of that, there can be multiple 'replaces', generating more number in the symbol. Your task is, depending on which way you expand to, give the sum of all the elements of plus symbol that you would obtain. Input ====== First line contains an integer T (1

Input Format

N/A

Output Format

N/A