Results are out and admission process has begun in most of the colleges. This is the story of two such young engineering aspirants, Ramesh and Suresh, who intend to make it big in life.
They met each other during the admission phase of some college and have become friends. But that does not mean they aren't competitors. They both have scored the exact same marks in JEE Mains and also in their boards and so, right now, it's a tie on who is more intelligent. No one likes ties, so in order to determine who is the smarter of them both they decided to ask a Mathematics Professor, at the college they currently are applying to, to give both of them a problem to solve and the one who solves it first is smarter. By now it should be evident that the strong point of both of them is Mathematics.
The mathematics professor had been in that college since its inception and had seen plenty such Ramesh and Suresh pairs competing each other. It was no big deal for him as this happened quite a lot and he found such competition healthy. He gave them both a very simple task which was to find the Ramanujan Number but not just any Ramanujan Number.
He would simply give them a number, N, and they would have to find the Nth Ramanujan Number. Also, finding the number just once would not be a wise option and so he would repeat the same thing several times.
You are here, not just to see who wins between Ramesh and Suresh. Your task is to help the professor. You don't expect him to remember all the Ramanujan Numbers by heart, do you? But in order to determine the winner, the professor must himself know the answer. Provide him with the answer key so that he shall determine the winner!
Input:
First line of input will contain a number, t. It is the number of numbers the professor gives them both. Each of the next t lines would contain a number, N.
Output:
t lines, each of which contain the Nth Ramanujan Number.
Constraints:
1 <= t <= 15
1 <= N <= 100