Problems
Lines
Lines
\includegraphics{https://static.e-olymp.com/content/7f/7ffaea86af91fcb4a919a30935a8630004c0f345.gif}
Consider a positive integer \textbf{N}. Let \textbf{A}, \textbf{B} and \textbf{C} be non-negative integers, such that \textbf{A}+\textbf{B}+\textbf{C}=\textbf{N}. Let there be \textbf{N} marked points on a line with an equal distance between neighboring ones. Draw lines at an angle of 45 degrees through the leftmost \textbf{A} points, draw lines at an angle of 90 degrees through the next B points, and at an angle of \textbf{135} degrees -- through the last \textbf{C} points. These lines will intersect in some of points.
For clarity look at the image, where \textbf{N}=5, \textbf{A}=1, \textbf{B}=2, \textbf{C}=2. There are 6 points of intersection.
Your task is quite simple -- for given \textbf{N} you are to count the sum of quantities of intersection points for all possible triples \textbf{A}, \textbf{B}, \textbf{C}
.
\InputFile
First line of input contains the quantity of tests \textbf{T} (\textbf{1} ≤ \textbf{T} ≤ \textbf{1000}).
Each of the next \textbf{T} lines contains an integer \textbf{N} (\textbf{2} ≤ \textbf{N} ≤ \textbf{10^6}) -- the quantity of points on the line in a current test.
\OutputFile
Output \textbf{T} lines of the form “Case #\textbf{A}: \textbf{B}”, where \textbf{A} is the number of test (beginning from 1), \textbf{B} is the sum of quantities of intersection points for given \textbf{N}.
Input example #1
3 2 3 5
Output example #1
Case #1: 3 Case #2: 13 Case #3: 91