Skip to content

Commit 6b95076

Browse files
Update leetcode_2112.md
1 parent 15bad71 commit 6b95076

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

leetcode_2112.md

+10
Original file line numberDiff line numberDiff line change
@@ -79,3 +79,13 @@ The airports with the most traffic are airports 1, 2, 3, and 4.
7979
```
8080

8181
# Solution
82+
```
83+
select airport_id from (
84+
select airport_id, dense_rank() over(order by sum(flights_count) desc) rnk from (
85+
select departure_airport as airport_id, flights_count from flights
86+
87+
union all
88+
89+
select departure_airport as airport_id, flights_count from flights ) tb ) tb1 where rnk = 1
90+
```
91+

0 commit comments

Comments
 (0)