4 ms·
Why do they not allow the inspection of the results past 1,000 It's probably a lot more work sorting the 1000th best result than the top 10 or 100. Imagine a s
by byoung2 10y ago
Why do they not allow the inspection of the results past 1,000
It's probably a lot more work sorting the 1000th best result than the top 10 or 100. Imagine a stadium full of people (your search results) and a guy at the podium asking for the tallest 10 people (top 10 results). You can do this efficiently by getting the tallest person from each section of the stadium, and then lining them up by height and taking the first 10 (sharding). But if you ask for 10 tallest people between 5'7.5613" and 5'7.5614" you're going to have thousands of people to sort, and very little to differentiate them (long tail).
- saghm 10y agoI'm not sure I follow your example; what if the ten tallest people are all on the same section?
- JimmyAustin 10y agoIf 100% accuracy is important then getting the top 10 from each section and then sorting then would be necessary. If you were willing to trade performance for accuracy then getting the top 1 from each section would probably give you a decent approximation. In the perfect accuracy case, if you were grabbing the range of 990-1000, you would need to grab the top 1000 from each section, which is 100x more data transfer. I don't work for Google, but given the amount of money they spend on building their own routers, they probably want to minimise that number.
- byoung2 10y agoThe approximation is better in this case since you only have the results I return and you can't independently audit every section to see if I'm accurate. Say I return the 7 foot guy from each section, but one section only had a 6'8" guy. Meanwhile there is a section that had 10 7 footers. You can't verify that without seeing my data.