Yep. There is an important lesson here, which applies in any large enterprise or web scale system. The fastest algorithms are going to be mathematical in nature. Pretty much any problem which has a converging solution has an analytical, non-summing solution like this. Better still, it scales and the complexity stays the same.

If you liked that, you might enjoy this.

http://goadingtheitgeek.blogspot.co.uk/2014/05/blast-from-past.html

Written by

EA, Stats, Math & Code into a fizz of a biz or two. Founder: Automedi & Axelisys. Proud Manc. Citizen of the World. I’ve been busy

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store