1244. Design A Leaderboard

3가지 기능이 있는 Leaderboard 클래스를 설계

  • addScore(playerId, score): 주어진 플레이어의 점수에 점수를 추가하여 순위표를 업데이트
  • top(K): 상위 K 플레이어의 점수 합계를 반환
  • reset(playerId): 주어진 ID를 가진 플레이어의 점수를 0으로 재설정(즉, 리더보드에서 삭제)

Continue reading

Pagination


© 2017. by yeopoong.github.io

Powered by yeopoong