![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
LeetCode之数据库(Mysql)
.NET跨平台
比较认真。编程就是算法和数据结构,算法和数据结构是编程的灵魂。
展开
-
177.Nth_Highest_Salary
Write a SQL query to get the nth highest salary from the Employee table.#+----+--------+#| Id | Salary |#+----+--------+#| 1 | 100 |#| 2 | 200 |#| 3 | 300 |#+----+--------+For example转载 2017-06-29 21:40:54 · 563 阅读 · 0 评论 -
178.Rank_Scores
Write a SQL query to rank scores. If there is a tie between two scores, both should have the same ranking. Note that after a tie,the next ranking number should be the next consecutive integer value. #+转载 2017-06-29 21:58:51 · 565 阅读 · 0 评论 -
180.Consecutive_Numbers
Write a SQL query to find all numbers that appear at least three times consecutively.#+----+-----+#| Id | Num |#+----+-----+#| 1 | 1 |#| 2 | 1 |#| 3 | 1 |#| 4 | 2 |#| 5 | 1 |#| 6转载 2017-06-29 22:42:30 · 940 阅读 · 0 评论 -
LeetCode 数据库181,182,183,184,185整理
181. Employees Earning More Than Their ManagersThe Employee table holds all employees including their managers. Every employee has an Id, and there is also a column for the manager Id.+----+-------+---转载 2017-07-02 18:33:20 · 549 阅读 · 0 评论 -
LeetCode 数据库262,601整理
The Trips table holds all taxi trips. Each trip has a unique Id, while Client_Id and Driver_Id are both foreign keys to the Users_Id at the Users table. Status is an ENUM type of (‘completed’, ‘cancell转载 2017-07-02 22:59:11 · 1456 阅读 · 0 评论