1020 - Sequence
Time Limit : 4 Second
Memory Limit : 128 MB
- You must have known the sequence define as follows:
for every i=1,2,3,...
You can easily prove that every postive number will appear in this sequence.
Now give you a postive number n,your task is to determine the first position n appears.
- Only one number n (0<n<400000).
- The first position n appears.The answer won't exceed 263-1
- sample input
1 2 3 4
- sample output
1 3 5 9
- 64位整型数，用long long定义，输出用%lld。