in reply to Re: Can I speed this up? (Algorithm error)
in thread Can I speed this up? (repetitively scanning ranges in a large array)
Going back to the example of position 1:
half size 0: there exists a range that covers 1,1
half size 1: there exists a range that covers 35,2
half size 2: there exists a range that covers 34,3
...
half size 8: there exists a range that covers 28,9 (e.g. 28,10)
half size 9: there is NO range that covers 27,10. DONE!
I hope it's more clear now.
(p.s. in your ASCII art it seems as if MAX=36, not 35, doesn't it?)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Can I speed this up? (Algorithm error)
by BrowserUk (Patriarch) on Nov 03, 2010 at 20:37 UTC |