You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tasks/58.md
+26-2Lines changed: 26 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,21 +3,45 @@
3
3
<imgsrc="./art/58.png"alt="solution" >
4
4
5
5
#### eng:
6
+
You are given three tables: Students, Friends and Packages. Students contains two columns: ID and Name. Friends contains two columns: ID and Friend_ID (ID of the ONLY best friend). Packages contains two columns: ID and Salary (offered salary in $ thousands per month).
6
7
7
8
8
9
10
+
Write a query to output the names of those students whose best friends got offered a higher salary than them. Names
11
+
must be ordered by the salary amount offered to the best friends. It is guaranteed that no two students got same
12
+
salary offer.
13
+
14
+
9
15
#### рус:
16
+
Вам дается три таблицы: Студенты, Друзья и Пакеты. Студенты содержит два столбца: идентификатор и имя. Друзья содержит две колонки: ID и Friend_ID (ID ЕДИНСТВЕННОГО лучшего друга). Пакеты содержат две колонки: ID и Salary (предлагаемая зарплата в тысячах долларов в месяц).
17
+
10
18
11
19
20
+
Напишите запрос для вывода имен тех студентов, чьим лучшим друзьям предложили более высокую зарплату, чем они. Имена
21
+
должны быть упорядочены по сумме зарплаты, предлагаемой лучшим друзьям. Гарантируется, что никакие два студента не
0 commit comments