Re:How Hacker News ranking algorithm works
by zackattack on Monday October 11, 2010 @10:25PM
(#1782073)
I would prefer PHP but seconded
[ Parent
| on HN ]
Re:How Hacker News ranking algorithm works
by sstrudeau on Monday October 11, 2010 @10:56PM
(#1782136)
This is pretty trivial but sure, something like:
function calculate_score($votes, $item_hour_age, $gravity=1.8) {
return ($votes - 1) / pow(($item_hour_age+2), $gravity);
}