MySQL 的CAST()和CONVERT()函数可用来获取一个类型的值,并产生另一个类型的值。两者具体的语法如下: 就是CAST(xxx AS 类型), CONVERT(xxx,类型)。 可以转换的类型是有限制的。这个类型可以是以下值其中的一个: 二进制,同带binary前缀的效果 : BINAR ...
分类:
数据库 时间:
2019-08-08 00:32:35
阅读次数:
146
problem 977. Squares of a Sorted Array solution: 参考1. Leetcode_easy_977. Squares of a Sorted Array; 完 ...
分类:
其他好文 时间:
2019-08-07 19:05:06
阅读次数:
64
A. Best Subsegment 显然,选择数列中的最大值当做区间(长度为$1$)。只要尝试最大值这个区间是否能扩展(左右两边值是否跟它一样就行了) C. Magic Ship 二分答案。容易看出,时刻符合单调性。若$d$天能到,那么$d + 1$也能到。因为可以保持跟风相反的方向就可以保持不动 ...
分类:
其他好文 时间:
2019-08-04 01:45:15
阅读次数:
109
If you are a fan of Harry Potter, you would know the world of magic has its own currency system -- as Hagrid explained it to Harry, "Seventeen silver ...
分类:
其他好文 时间:
2019-08-03 10:27:47
阅读次数:
102
$subtask3$ 当$t[son]<=t[ansetor]$时$son$的贡献才能被计算,即求最长上升子序列$o(nlogn)$ ...
分类:
其他好文 时间:
2019-07-29 10:24:03
阅读次数:
142
大意: 给定$N^3$立方体, 每个单位立方体权值为三个坐标异或, 每次沿坐标轴切一刀, 得分为两半内权值和的乘积, 求切成$n^3$块的最大得分. 可以发现得分与切法无关, 假设每个点权值为$a_i$, 就有$ans=\frac{(\sum a_i)^2-\sum a_i^2}{2}$. 从而转化 ...
分类:
其他好文 时间:
2019-07-26 02:00:38
阅读次数:
104
You are given a line of nn colored squares in a row, numbered from 11 to nn from left to right. The ii-th square initially has the color cici. Let's s ...
分类:
其他好文 时间:
2019-07-24 21:09:13
阅读次数:
116
problem 840. Magic Squares In Grid 参考 1. Leetcode_easy_840. Magic Squares In Grid; 完 ...
分类:
其他好文 时间:
2019-07-19 19:04:00
阅读次数:
64