Description Given a n × n matrix A and a positive integer k, find the sum S = A + A2 + A3 + … + Ak. Given a n × n matrix A and a positive integer k, f ...
分类:
其他好文 时间:
2018-08-06 21:47:39
阅读次数:
244
Implement strStr function in O(n + m) time. strStr return the first index of the target string in a source string. The length of the target string is ...
分类:
其他好文 时间:
2018-08-06 14:40:35
阅读次数:
162
<题目链接> 题目大意: 给出一个字符串,求其字串在该字符串中循环的最大周期。 解题分析: length=len-Next[len],len为该字符串的最小循环节,如果len%length==0,那么周期就为len/lenght,如果不能整除,则说明该字符串的字串不具有周期性,输出1。 KMP最小循 ...
分类:
其他好文 时间:
2018-08-06 00:43:30
阅读次数:
132
1.大端和小端的问题 ? 对于整型、长整型等数据类型,Big endian 人为第一个字节是最高位字节( 按照从低地址到高地址的顺序存放数据的高位字节到低位字节 ),而 Little endian 则相反,它认为第一个字节是低位字节(按照从低地址到高地址的顺序存放数据的低位字节到高位字节)。 (1) ...
分类:
其他好文 时间:
2018-08-04 13:38:01
阅读次数:
134
当mysql的root用户密码被遗忘时可通过下列步骤进行重新设置(在管理员权限的cmd窗口下执行) 1.关闭启动的mysql服务 net stop mysql 2.执行下面的命令可以免密进入mysql mysqld -nt --skip-grant-tables 3.重新打开管理员cmd执行下面的命 ...
分类:
数据库 时间:
2018-08-03 23:41:04
阅读次数:
216
A sequence a1,a2,…,ana1,a2,…,an is called good if, for each element aiai, there exists an element ajaj (i≠ji≠j) such that ai+ajai+aj is a power of two ...
分类:
其他好文 时间:
2018-08-01 18:13:06
阅读次数:
147
链接:http://poj.org/problem?id=2406 Power Strings Time Limit: 3000MS Memory Limit: 65536K Description Given two strings a and b we define a*b to be thei ...
分类:
其他好文 时间:
2018-07-31 17:23:53
阅读次数:
139
360 FireLine 360火线,静态代码检查工具 activate-power-mode 花里胡哨的 Alibaba Java Coding Guidelines 阿里巴巴代码规约 bashSupport bash brownbat-redis-cli redis 客户端 builder ge ...
分类:
其他好文 时间:
2018-07-30 16:34:15
阅读次数:
666
数值的整数次方 给定一个double类型的浮点数base和int类型的整数exponent。求base的exponent次方 注意exponent的正负 使用位运算 class Solution { public: double Power(double base, int exponent) { ...
分类:
其他好文 时间:
2018-07-30 11:16:35
阅读次数:
133
Portal broken qwq Description 现在有一个树根,标号为$1$,我们要加入一些节点使得它变成一棵树 ? 接下来加入的每一个节点都有一个能量值为$v[i]$,我们定义$d[i]$表示一个节点的儿子数$+1$,$son[i]$表示这个节点的儿子列表,一个节点的好看度为$w[i] ...
分类:
其他好文 时间:
2018-07-28 11:41:53
阅读次数:
114