2017年11月24日

leetcode 182. Duplicate Emails having的用法 SQL执行顺序

摘要: https://leetcode.com/problems/duplicate-emails/description/ 首先sql的执行顺序是 from-->where-->group by >having-->select-->order by 所以用了group后,用where判断是错误的 ht 阅读全文

posted @ 2017-11-24 14:29 stupid_one 阅读(128) 评论(0) 推荐(0) 编辑

leetcode 181 Employees Earning More Than Their Managers 不会分析的数据库复杂度

摘要: https://leetcode.com/problems/employees-earning-more-than-their-managers/description/ 老师上课没分析这些的复杂度,我大概认为子查询要O(n^2) 一开始,直接用了子查询,2400ms.... # Write you 阅读全文

posted @ 2017-11-24 13:34 stupid_one 阅读(150) 评论(0) 推荐(0) 编辑

17082 两个有序数序列中找第k小(优先做) O(logn)

摘要: 17082 两个有序数序列中找第k小(优先做) 时间限制:1000MS 内存限制:65535K提交次数:0 通过次数:0 题型: 编程题 语言: G++;GCC;VC Description 输入格式 第一行有三个数,分别是长度m、长度n和k,中间空格相连(1<=m,n<=100000; 1<=k< 阅读全文

posted @ 2017-11-24 12:38 stupid_one 阅读(675) 评论(0) 推荐(0) 编辑

导航