码迷,mamicode.com
首页 > 其他好文
计时器开始和关闭
计时器
分类:其他好文   时间:2015-05-16 00:01:11    阅读次数:251
高效的C指针
高效的C指针 cnyinlinux ? 指针,被称做C语言编程的精华。其闻名数十年的秘诀在于,高效二字。今天我们讲的就是,指针是如何做到了这一切的。 ? 经常你会看到这样的形式: XXX * func(int para1,…);//函数参数...
分类:其他好文   时间:2015-05-15 22:57:52    阅读次数:300
动态调用最新测试类
需求分析:很多时候,我们不经意的经常要写一些测试方法,然而每次花时间都去新建一个项目,显然非常浪费时间。下面我针对测试项目需求,做了一个小型的测试项目,以供经常对一些方法和类做测试使用的项目来使用。...
分类:其他好文   时间:2015-05-15 22:57:32    阅读次数:254
子字符串包含
Description: 给定两个分别由字母组成的字符串A和字符串B,字符串B的长度比字符串A短。请问,如何最快地判断字符串B中所有字母是否都在字符串A里? 为了简单起见,我们规定输入的字符串只包含大写英文字母,请实...
分类:其他好文   时间:2015-05-15 22:57:37    阅读次数:272
LintCode-乘积最大子序列
找出一个序列中乘积最大的连续子序列(至少包含一个数)。 样例 比如, 序列 [2,3,-2,4] 中乘积最大的子序列为 [2,3] ,其乘积为6。 分析:访问到每个点的时候,以该点为子序列的末尾的乘积,要么是该点本身,要么是该点乘以以前一点为末尾的序列,注意乘积负负得正,故需要记录前面的最大最小值。 代码: class Solution { public: /** ...
分类:其他好文   时间:2015-05-15 22:55:22    阅读次数:212
dll的内存申请和释放问题--Debug程序正常而Release程序崩溃
C++编程中经常遇到这样的需求:主函数需要调用一个dll库函数并返回一块大小不定的存储着处理结果的内存,这时容易想到两种选择:一是使用vector的引用作为形参,二是使用指针,在主函数中定义指针,而在dll库函数中申请内存。...
分类:其他好文   时间:2015-05-15 22:57:41    阅读次数:447
初级驱动模板之实现【驱动模板信息】
博客:http://blog.csdn.net/muyang_ren /************************************************************************* > File Name: hello.c > Author: 梁惠涌 > Addr: > Created Time: 2015年05月15日 星期五 20时16分57秒...
分类:其他好文   时间:2015-05-15 22:55:47    阅读次数:200
错误代码: 1449 The user specified as a definer ('root'@'%') does not exist
1、错误描述 1 queries executed, 0 success, 1 errors, 0 warnings 查询:call insertDate() 错误代码: 1449 The user specified as a definer ('root'@'%') does not exist 执行耗时 : 0 sec 传送时间 : 0 sec 总耗时 : 0.17...
分类:其他好文   时间:2015-05-15 22:54:08    阅读次数:122
Scheme change not implemented
1、错误描述 2、错误原因 3、解决办法...
分类:其他好文   时间:2015-05-15 22:54:26    阅读次数:122
【FZU】Problem 2056 最大正方形
这题的关键就是预处理矩阵利用 dp[i][j] = dp[i - 1][j] + dp[i][j - 1] - dp[i-1][j-1] 递推出矩阵,使得我们以后每次已经利用O(1)的复杂度计算任意一块矩阵 之后枚举正方形左上角的坐标二分边长,时间复杂度为n^2 log(n) #include #include #include using namespace std; const int...
分类:其他好文   时间:2015-05-15 22:53:32    阅读次数:108
【FZU】Problem 2059 MM(离线处理并查集)
离线处理,并查集 #include #include #include using namespace std; const int maxn = 100005; struct Node{ int id,value; }node[maxn],input[maxn]; bool cmp(Node p,Node q){ return p.value > q.value;...
分类:其他好文   时间:2015-05-15 22:55:32    阅读次数:117
Attribute name "aphmodel" associated with an element type "mxg" must be followed by the ' = ' charac
1、错误描述 org.apache.batik.transcoder.TranscoderException: null Enclosed Exception: Attribute name "aphmodel" associated with an element type "mxg" must be followed by the ' = ' character. at org.apach...
分类:其他好文   时间:2015-05-15 22:52:26    阅读次数:587
求三个数值的中间值的宏定义
怎么用一个宏来求三个数值的中间值呢?请看:...
分类:其他好文   时间:2015-05-15 22:54:40    阅读次数:114
Column 'id' in where clause is ambiguous
1、错误描述 org.hibernate.exception.ConstraintViolationException: error executing work at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:72) at org.hiber...
分类:其他好文   时间:2015-05-15 22:52:01    阅读次数:891
树的子结构
题目:输入两颗二叉树A和B,判断B是不是A的子结构。二叉树结点的定义如下: struct BinaryTreeNode{ int m_nValue; BinaryTreeNode *m_pLeft; BinaryTreeNode *m_pRight; }; //在数A中查找与树B根结点值相同的结点,然后递归判断,查找过程也是递归 bool HasSubTree(BinaryTreeN...
分类:其他好文   时间:2015-05-15 22:51:50    阅读次数:215
Codeforces544E:Remembering Strings(状态压缩)
You have multiset of n strings of the same length, consisting of lowercase English letters. We will say that those strings are easy to remember if for each string there is some position i and some l...
分类:其他好文   时间:2015-05-15 22:53:40    阅读次数:136
Libsvm自定义核函数【转】
1. 使用libsvm工具箱时,可以指定使用工具箱自带的一些核函数(-t参数),主要有:-t kernel_type : set type of kernel function (default 2)0 -- linear: u'*v1 -- polynomial: (gamma*u'*v + co...
分类:其他好文   时间:2015-05-15 22:51:50    阅读次数:211
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!