select table_schema, table_name from information_schema.tables where table_name not in (select distinct table_name from information_schema.columns whe ...
分类:
数据库 时间:
2020-03-20 19:58:30
阅读次数:
263
【Codeforces1234D】Distinct Characters Queries 的题解 ...
分类:
其他好文 时间:
2020-03-18 23:28:27
阅读次数:
44
Given a string s and a string t, check if s is subsequence of t. You may assume that there is only lower case English letters in both s and t. t is po ...
分类:
其他好文 时间:
2020-03-18 11:13:53
阅读次数:
47
Given a string S, count the number of distinct, non-empty subsequences of S . Since the result may be large, return the answer modulo 10^9 + 7. Exampl ...
分类:
其他好文 时间:
2020-03-18 09:38:23
阅读次数:
52
from——where——group by——having——select——distinct——order by——limit 1.找到表:from 2.拿着where指定的约束条件,去文件/表中取出一条条记录 3. 将取出的一条条记录进行分组group by,如果没有group by,则整体作为 ...
分类:
数据库 时间:
2020-03-16 10:03:29
阅读次数:
82
Given a m * n matrix of distinct numbers, return all lucky numbers in the matrix in any order. A lucky number is an element of the matrix such that it ...
分类:
其他好文 时间:
2020-03-16 09:41:48
阅读次数:
34
原文:ORDER BY导致索引使用不理想 在MySQL中经常出现未按照理想情况使用索引的情况,今天记录一种Order by语句的使用导致未按预期使用索引的情况。 1. 问题现象 1.1 SQL语句: SELECT DISTINCT p.* FROM tb_name p WHERE 1=1 AND p... ...
分类:
其他好文 时间:
2020-03-15 22:37:24
阅读次数:
86
You are given an array aa consisting of nn integers. Your task is to determine if aa has some subsequence of length at least 33 that is a palindrome. ...
分类:
其他好文 时间:
2020-03-14 23:35:49
阅读次数:
96
维护两个单调队列一个递增一个递减 如果两个差值大于l,那么把位置小的往后移,因为这样才能保证合法,不然比如最大值在1处,最小值在2处,现在我们移动最小值是不可能的,因为最小值始终在最大值和右端点的中间,无法移动,只能移动最大值,那么注意的是,如果移动后合法,那么当前的有效区间跟移动后在哪无关,其实是 ...
分类:
其他好文 时间:
2020-03-14 21:48:11
阅读次数:
46
MySQL-DAY02 1. 查询结果去重 mysql> select distinct job from emp; // distinct关键字去除重复记录。 注意:distinct只能出现在所有字段的最前面。 2. 连接查询 2.1 连接查询的分类 根据语法出现的年代来划分的话,包括: SQL9 ...
分类:
数据库 时间:
2020-03-14 13:04:33
阅读次数:
78