ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1209. 1, 10, 100, 1000...

WHY
Posted by nlln 12 Apr 2010 14:21
this question is equal to whether 8*k-7 is a Square number
A(i) shows  1's position in the sequence
first  A(1)=1
A(2)-A(1)=1
A(3)-A(2)=2
.
.
.
A(n)-A(n-1)=(n-1)
add both side of the “=”
we get An=(n^2-3n+4)/2
       exchange the equation we get
       8*A(n)-7=(2n-3)(2n-3)

but I can't AC```

Edited by author 12.04.2010 15:10
Re: WHY
Posted by Dennis Meng 19 May 2011 00:25
It doesn't seem to work for the case k = 4.