Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 7ef911b

Browse files
committed
feat: add solutions to lc problems: No.2668,2669
* No.2668.Find Latest Salaries * No.2669.Count Artist Occurrences On Spotify Ranking List
1 parent d0e8c21 commit 7ef911b

File tree

6 files changed

+72
-4
lines changed

6 files changed

+72
-4
lines changed

‎solution/2600-2699/2668.Find Latest Salaries/README.md‎

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,19 @@ Each row contains employees details and their yearly salaries, however, some of
8080
<!-- 这里可写当前语言的特殊实现逻辑 -->
8181

8282
```sql
83-
83+
# Write your MySQL query statement below
84+
SELECT
85+
emp_id,
86+
firstname,
87+
lastname,
88+
max( salary ) AS salary,
89+
department_id
90+
FROM
91+
Salary
92+
GROUP BY
93+
emp_id
94+
ORDER BY
95+
emp_id;
8496
```
8597

8698
<!-- tabs:end -->

‎solution/2600-2699/2668.Find Latest Salaries/README_EN.md‎

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,19 @@ Each row contains employees details and their yearly salaries, however, some of
7474
### **SQL**
7575

7676
```sql
77-
77+
# Write your MySQL query statement below
78+
SELECT
79+
emp_id,
80+
firstname,
81+
lastname,
82+
max( salary ) AS salary,
83+
department_id
84+
FROM
85+
Salary
86+
GROUP BY
87+
emp_id
88+
ORDER BY
89+
emp_id;
7890
```
7991

8092
<!-- tabs:end -->
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Write your MySQL query statement below
2+
SELECT
3+
emp_id,
4+
firstname,
5+
lastname,
6+
max( salary ) AS salary,
7+
department_id
8+
FROM
9+
Salary
10+
GROUP BY
11+
emp_id
12+
ORDER BY
13+
emp_id;

‎solution/2600-2699/2669.Count Artist Occurrences On Spotify Ranking List/README.md‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,17 @@ Each row contains an id, track_name, and artist.
6464
<!-- 这里可写当前语言的特殊实现逻辑 -->
6565

6666
```sql
67-
67+
# Write your MySQL query statement below
68+
SELECT
69+
artist,
70+
count( 1 ) AS occurrences
71+
FROM
72+
Spotify
73+
GROUP BY
74+
artist
75+
ORDER BY
76+
occurrences DESC,
77+
artist;
6878
```
6979

7080
<!-- tabs:end -->

‎solution/2600-2699/2669.Count Artist Occurrences On Spotify Ranking List/README_EN.md‎

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,17 @@ Each row contains an id, track_name, and artist.
5858
### **SQL**
5959

6060
```sql
61-
61+
# Write your MySQL query statement below
62+
SELECT
63+
artist,
64+
count( 1 ) AS occurrences
65+
FROM
66+
Spotify
67+
GROUP BY
68+
artist
69+
ORDER BY
70+
occurrences DESC,
71+
artist;
6272
```
6373

6474
<!-- tabs:end -->
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Write your MySQL query statement below
2+
SELECT
3+
artist,
4+
count( 1 ) AS occurrences
5+
FROM
6+
Spotify
7+
GROUP BY
8+
artist
9+
ORDER BY
10+
occurrences DESC,
11+
artist;

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /