目前只用了单机版的jedis,集群搭建成功,但接口测试有问题
1.和jedis服务连接
public class RedisUtil {
private static String JEDIS_SERVER="10.0.0.18";
private static int JEDIS_PORT=6379;
protected Jedis jedis = new Jedi...
分类:
其他好文 时间:
2015-07-07 00:58:54
阅读次数:
121
人生最美好的东西,就是他同别人的友谊。——林肯
(define set?
(lambda (l)
(cond
((null? l) #t)
((member? (car l) (cdr l)) #f)
(else (set? (cdr l))))))
(set? '(apples peaches pear plums))
(set? '(ap...
分类:
其他好文 时间:
2015-07-07 00:55:57
阅读次数:
130
题目描述
编写程序,输入一个正整数n,求下列算式的值。要求定义和调用函数fact(k)计算k的阶乘。
1+1/2!+ .... +1/n!
计算结果保存在double类型变量中。
接口说明
原型:
void GetResult(int InputNum, double *NumResult);
输入参数:
Int InputNu...
分类:
其他好文 时间:
2015-07-07 00:58:32
阅读次数:
140
题目描述
链接地址
解法题目描述Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x.You should preserve the original relative order of the nodes...
分类:
其他好文 时间:
2015-07-07 00:55:14
阅读次数:
116
【解析】代数变形+高斯消元
[分析]
根据题目下面的提示,设x[i][j]表示第i个点在第j维的坐标,r[j]为圆心在第j维的坐标
可以知道:
dis=根号(∑(x[i][j]-r[j])^2)。
由于平方的非负性,所以可以推出 dis^2=∑(x[i][j]-r[j])^2。
根据平方和公式,(x[i][j]-r[j])^2=r[j]^2+x[i][j]^2-2*x[i][j]*...
分类:
其他好文 时间:
2015-07-07 00:56:53
阅读次数:
115
例1:void CTextDlg::OnPaint(){Graphics graphics(this->m_hWnd);LinearGradientBrush linGrBrush( Point(0,0), Point(200,0), Color(255,255,0,0), Color(25...
分类:
其他好文 时间:
2015-07-07 00:56:18
阅读次数:
198
Swing类包中有一个很有用的流过滤器,ProgressMonitorInputStream,它可以自动弹出一个对话框,监视已经读取了多少流。进度监视器流使用InputStream类的available方法来确定流中的总字节数。不过available方法只报告流中可访问的、未中断的字节数。进度监视器...
分类:
其他好文 时间:
2015-07-07 00:57:07
阅读次数:
108
Xamarin.Form 中没有 FlipView, 也没有 CarouselView , 有的只是一个 CarouselPage, 它是一个 Page, 不是一个 View !Windows Phone 8.1 下有个控件叫 FlipView, 但是它不存于在 WP Siliverlight !而...
分类:
其他好文 时间:
2015-07-07 00:56:07
阅读次数:
251
基本思想就是:二叉树的中序非递归遍历 1 /** 2 * Definition for a binary tree node. 3 * struct TreeNode { 4 * int val; 5 * TreeNode *left; 6 * TreeNode *...
分类:
其他好文 时间:
2015-07-07 00:56:35
阅读次数:
114
DDD : Domain Driven Design CQRS :Command Query Responsibility Seperation(命令查询职责分离)的缩写 把查询数据 同程为 Query (查询) 改变状态叫做 Command (命令) CRUD : (Create, Read, U...
分类:
其他好文 时间:
2015-07-07 00:56:14
阅读次数:
119
这道题就是数点 divide and conquerclass Solution: # @param {TreeNode} root # @param {integer} k # @return {integer} def kthSmallest(self, root, k)...
分类:
其他好文 时间:
2015-07-07 00:55:14
阅读次数:
108
Java源代码是以*.java的纯文本文件,可以使用任何文本编辑器编写,但不可以执行。 JDK是Java语言的开发包,可以将*.java文件编译成可执行Java文件。 可执行Java程序需要JVM才可以运行。 JDK中包含了JRE,而JRE中又包含了JVM。如果安装了JDK,则不必再次安装JRE。 ...
分类:
其他好文 时间:
2015-07-07 00:53:07
阅读次数:
183
1000纯属适应题1003做的时候花了很久,现在看好像也不难1004适应题,求下平均就行1005要读懂题就行1007 逆序数,discuss方法1046全部暴搜一遍。。1118照抄2606没看题。。WA。。RE全占了1207貌似我的方法超级麻烦1247读懂题目比较麻烦1248暴力过的。。1250一整...
分类:
其他好文 时间:
2015-07-07 00:54:38
阅读次数:
99
一、常用方法1public char charAt(int index) 返回字符串中第index个字符public int length() 返回字符串的长度public int indexOf(String str) 返回字符串中出现str的第一个位置public int indexOf(Str...
分类:
其他好文 时间:
2015-07-07 00:54:28
阅读次数:
101