add basic ranking algorithm
Merge pull request #1 from robertberry/ranking-algorithm

add basic ranking algorithm