首先,定义如下类A:
class A
{
private:
static int val_s;
public:
static int getVal(){cout << "call getVal in A..." << endl;return val_s;}
};
我们可以看到,上述类的定义中包含静态成员变量val_s 和静态成员函数getVal() ,对于静态的成员变量,一般...
分类:
编程语言 时间:
2014-09-06 12:29:23
阅读次数:
251
fetcher.max.crawl.delay 默认是30秒,这里改为 5秒修改nutch-default.xml fetcher.max.crawl.delay 5 If the Crawl-Delay in robots.txt is set to greater than this val.....
分类:
其他好文 时间:
2014-09-05 12:37:31
阅读次数:
193
一开始的思路是:中序遍历+判断遍历后的数组,时间空间都不是最优果然超时了 1 /** 2 * Definition for binary tree 3 * struct TreeNode { 4 * int val; 5 * TreeNode *left; 6 * ...
分类:
其他好文 时间:
2014-09-04 23:35:50
阅读次数:
393
递归 1 /** 2 * Definition for binary tree 3 * struct TreeNode { 4 * int val; 5 * TreeNode *left; 6 * TreeNode *right; 7 * TreeNode...
分类:
其他好文 时间:
2014-09-04 22:16:00
阅读次数:
228
重新写了下,代码看着清爽多了 1 /** 2 * Definition for singly-linked list. 3 * struct ListNode { 4 * int val; 5 * ListNode *next; 6 * ListNode(int x...
分类:
其他好文 时间:
2014-09-04 20:54:00
阅读次数:
162
#include #include const int maxn = 1000;int Num_of_Player;int m_val;typedef struct{ int num, password; struct LNode *next;}*players, lnode;void ...
分类:
其他好文 时间:
2014-09-04 18:23:49
阅读次数:
242
#加载winapi
$ini = Add-Type -memberDefinition @"
[DllImport("Kernel32")]
public static extern long WritePrivateProfileString (
string section ,
string key ,
string val ,
string filePath );
[DllImport(...
<form?action=""?method="get">
年<input?type="text"??name="y"?value="2014"?/>月<input?type="text"??name="m"?value="<?php?echo?$_GET[‘m‘];??>"?/>日<input?type="text"??name="d"?val...
分类:
其他好文 时间:
2014-09-03 19:58:37
阅读次数:
210
#include
#include
using namespace std;
typedef long long LL;
const int maxn = 100010;
int pre[maxn], ch[maxn][2], sz[maxn];
int root, top1;
int s[maxn], top2;//内存池
LL sum[maxn];
int val[maxn], add...
分类:
其他好文 时间:
2014-09-03 14:58:56
阅读次数:
264
{ wait:90, hsTime:function(that){ if (this.wait == 0) { $('#hsbtn').removeAttr("disabled").val('重发短信验证码'); ...
分类:
Web程序 时间:
2014-09-03 09:35:56
阅读次数:
212