daily pastebin goal
22%
SHARE
TWEET

Untitled

a guest Feb 24th, 2012 1,284 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ; Votes divided by the age in hours to the gravityth power.
  2. ; Would be interesting to scale gravity in a slider.
  3.  
  4. (= gravity* 1.8 timebase* 120 front-threshold* 1
  5.    nourl-factor* .4 lightweight-factor* .3 )
  6.  
  7. (def frontpage-rank (s (o scorefn realscore) (o gravity gravity*))
  8.   (* (/ (let base (- (scorefn s) 1)
  9.           (if (> base 0) (expt base .8) base))
  10.         (expt (/ (+ (item-age s) timebase*) 60) gravity))
  11.      (if (no (in s!type 'story 'poll))  1
  12.          (blank s!url)                  nourl-factor*
  13.          (lightweight s)                (min lightweight-factor*
  14.                                              (contro-factor s))
  15.                                         (contro-factor s))))
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top