Logic to this question?

codeforces

#1

What could possibly be the logic to this question?
http://codeforces.com/contest/784/problem/A


#2

I tried the same problem yesterday. I too was baffled after trying for a while!
Then I read the tutorial and it said that traditionally first problem in such contest is about googling out the answer. If you google the title of the problem you might find some paper and then it is simply copying the sequence.
Here’s the tutorial : LINK. It can explain you much more than I do so please have a look!
Happy fooling around xD


#3

But how could number 3 could give 27 then, and how could number 1 can give 4 when 1 doesn’t have any prime factor…


#4

1 and 3 just denote the position ie 1st such number or 3rd such number.

4 is the first number which has that property


#5

oh okay…this question’s logic was something i could have never come across if i had not asked on the forum.