max.hpp/* The following code example is taken
from the book * "C++ Templates - The Complete Guide" * by David Vandevoorde and
Nicolai M. Josuttis, Add...
分类:
其他好文 时间:
2014-05-10 08:18:25
阅读次数:
394
今天在创建数据源的时候报了这么一个错Invalidbyte3of3-byteUTF-8sequence.上网一查,说是有中文,字体不相符,可是我没有写中文,为了能继续往后进行,修改了如下文件在start-pentaho.bat中添加了一句代码修改前IF"%BITS%"=="64"(
setCATALINA_OPTS=-Xms1024m-Xmx2048m-XX:Max..
分类:
其他好文 时间:
2014-05-09 21:43:58
阅读次数:
425
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4717
思路:第一次写三分法,原理和二分法其实是一样的,计算过程两边for,时间复杂度为O(n^2log(n))
代码:
#include
#include
#include
const double eps = 1e-6;
const int N = 305;
#define max(a...
分类:
其他好文 时间:
2014-05-09 21:11:49
阅读次数:
359
一、数学库
1. 随机数
math.randomseed(os.time()); -- 设置随机种子
for i=1, 100 do
print(math.random(-1000,1000)); -- 随机区间 [-1000,1000], math.random(1000) 表示 [1,1000]
end;
2. 最大,最小值
math.max...
分类:
其他好文 时间:
2014-05-09 20:58:11
阅读次数:
669
题目描述:在一个二维数组中,每一行都按照从左到右递增的顺序排序,每一列都按照从上到下递增的顺序排序。请完成一个函数,输入这样的一个二维数组和一个整数,判断数组中是否含有该整数。输入:输入可能包含多个测试样例,对于每个测试案例,输入的第一行为两个整数m和n(1
2 #define MAX 100 3 ...
分类:
其他好文 时间:
2014-05-09 20:28:29
阅读次数:
231
1.响应式图片
class="img-responsive"通过添加.img-responsiveclass可以让Bootstrap
3中的图片对响应式布局的支持更友好。其实质是为图片赋予了max-width: 100%;和height:
auto;属性,可以让图片按比例缩放,不超过其父元素的尺寸。...
分类:
Web程序 时间:
2014-05-09 19:26:13
阅读次数:
439
单词不换行
word-break:"break-all"text-overflow:ellipsis;
超出部分用...代替overflow:hidden;超出不分隐藏字体显示在一行 white-space:"nowrap"想要字体换行显示
max-height:""; 原价...
分类:
其他好文 时间:
2014-05-09 07:45:10
阅读次数:
238
在响应式(或自适应)设计中要用到Media
Queries这个CSS属性,但在某些时候我们需要对Media Queries进行动态操作,这时候可以使用Javascript。如以下Media
Queries的代码:@media all and (max-width: 700px) { body ...
分类:
编程语言 时间:
2014-05-09 05:51:04
阅读次数:
334
dp[i]:以第i个字符为max,左边的可以构成的上升子序列的个数 。
dp2[i];以第i个字符为max,右边的可以构成的下降子序列的个数 。
num[i][j];在第i个位置以字符j为结尾的上升子序列的个数
num2[i][j];在第i个位置以字符j为开头的下降子序列的个数
很容易的推出状态转移:
int x=str[i-1]-'a';
for(j=0;j
...
分类:
其他好文 时间:
2014-05-09 02:24:33
阅读次数:
289
题意:求长度不超过K的最大的连续序列的和
思路:采用单调队列,我们要求的是Max{sum[i]-sum[j]}(i-j#include
#include
#include
#include
using namespace std;
const int MAXN = 1000005;
const int INF = 0x3f3f3f3f;
int n,k;
int arr[MAXN],s...
分类:
其他好文 时间:
2014-05-09 01:57:07
阅读次数:
264