上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 34 下一页
摘要: 地址:https://leetcode-cn.com/problems/rising-temperature/ ## 给定一个 Weather 表,编写一个 SQL 查询,来查找与之前(昨天的)日期相比温度更高的所有日期的 Id。 示例: 给定一个 Weather 表,编写一个 SQL 查询,来查找 阅读全文
posted @ 2020-03-26 11:20 花花妹子。 阅读(148) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/employees-earning-more-than-their-managers/ ## 编写一个 SQL查询,交换所有的 f 和 m 值(例如,将所有 f 值更改为 m,反之亦然 示例: Employee 表包含所有员工, 阅读全文
posted @ 2020-03-26 10:52 花花妹子。 阅读(195) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/swap-salary/submissions/ ## 编写一个 SQL查询,交换所有的 f 和 m 值(例如,将所有 f 值更改为 m,反之亦然 示例: 给定一个 salary 表,如下所示,有 m = 男性 和 f = 女性 阅读全文
posted @ 2020-03-25 16:04 花花妹子。 阅读(501) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/length-of-last-word/ <?php /** 给定一个仅包含大小写字母和空格 ' ' 的字符串 s,返回其最后一个单词的长度。如果字符串从左向右滚动显示,那么最后一个单词就是最后出现的单词。 如果不存在最后一个单 阅读全文
posted @ 2020-03-25 14:38 花花妹子。 阅读(102) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/search-insert-position/ <?php /** 给定一个排序数组和一个目标值,在数组中找到目标值,并返回其索引。如果目标值不存在于数组中,返回它将会被按顺序插入的位置。 你可以假设数组中无重复元素。 示例 1 阅读全文
posted @ 2020-03-25 11:41 花花妹子。 阅读(231) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/not-boring-movies/ ## 编写一个 SQL查询,找出所有影片描述为非 boring (不无聊) 的并且 id 为奇数 的影片,结果请按等级 rating 排列 示例: 某城市开了一家新的电影院,吸引了很多人过来 阅读全文
posted @ 2020-03-25 09:32 花花妹子。 阅读(378) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/reverse-string/ <?php /** 编写一个函数,其作用是将输入的字符串反转过来。输入字符串以字符数组 char[] 的形式给出。 不要给另外的数组分配额外的空间,你必须原地修改输入数组、使用 O(1) 的额外空 阅读全文
posted @ 2020-03-24 14:05 花花妹子。 阅读(158) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/classes-more-than-5-students/ ## 请列出所有超过或等于5名学生的课。 示例: 有一个courses 表 ,有: student (学生) 和 class (课程)。 请列出所有超过或等于5名学生的 阅读全文
posted @ 2020-03-24 10:46 花花妹子。 阅读(146) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/big-countries/ ## 编写一个SQL查询,输出表中所有大国家的名称、人口和面积。 示例: 这里有张 World 表 + + + + + + | name | continent | area | populatio 阅读全文
posted @ 2020-03-24 09:29 花花妹子。 阅读(213) 评论(0) 推荐(0)
摘要: 地址:https://leetcode-cn.com/problems/number-of-steps-to-reduce-a-number-to-zero/ <?php /** 给你一个非负整数 num ,请你返回将它变成 0 所需要的步数。 如果当前数字是偶数,你需要把它除以 2 ;否则,减去 阅读全文
posted @ 2020-03-23 17:45 花花妹子。 阅读(423) 评论(0) 推荐(0)
上一页 1 ··· 18 19 20 21 22 23 24 25 26 ··· 34 下一页