728x90
https://www.hackerrank.com/challenges/full-score/problem?isFullScreen=true
Top Competitors | HackerRank
Query a list of top-scoring hackers.
www.hackerrank.com
만점을 맞은 challenge_id 개수가 2개 이상인 것들을
challenge_id 개수 내림차순, hacker_id 오름차순으로 정렬하기!
select s.hacker_id
, h.name
from submissions s
left join challenges c on s.challenge_id = c.challenge_id
left join difficulty d on c.difficulty_level = d.difficulty_level
left join hackers h on s.hacker_id = h.hacker_id
where s.score = d.score
group by s.hacker_id
, h.name
having count(s.challenge_id) > 1
order by count(s.challenge_id) desc
, s.hacker_id
728x90
'𝙎𝙌𝙇' 카테고리의 다른 글
[HackerRank] Challenges (0) | 2023.07.12 |
---|---|
[HackerRank] Olivander's Inventory (0) | 2023.07.10 |
[HackerRank] The Report (0) | 2023.07.07 |
[HackerRank] MySQL에서 median 중앙값 구하기 (Weather Observation Station 20) (0) | 2023.07.07 |
[HackerRank] New Companies (0) | 2023.07.05 |