My clear solution


  • 0
    F
    select scores.Score, count(ranking.Score) as Rank
    from scores, (select distinct Score from scores) ranking
    where ranking.score>=scores.Score
    group by scores.Id
    order by scores.Score desc
    

Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.