sphinx由于中文分词效果不佳,于是就有国内牛人给它改装了,sphinx-for-chinese就是其中一个。本包集成了字典,初始化时需要生成字典,务必检查字典源文件是utf-8格式的,见下文。环境CentOS6X64安装步骤yuminstallyum-utils-y
rpm-ivhsphinx-for-chinese-2.2.1-r4311.el6.src...
分类:
其他好文 时间:
2014-11-22 23:20:00
阅读次数:
271
函数参数外部变量名一般情况下你可以不指定外部变量名,直接调用函数:func helloWithName(name: String, age: Int, location: String) {
println("Hello \(name). I live in \(location) too. When is your \(age + 1)th birthday?")
}
helloWit...
分类:
编程语言 时间:
2014-11-22 21:40:26
阅读次数:
300
//------------------------通过获取系统时间,添加定时器和添0操作完成日期和时间的显示clock / / The th : :
分类:
其他好文 时间:
2014-11-22 13:16:33
阅读次数:
129
package LinkList.onewaycircular;
public class Node {
public int data;
public Node next;
//头结点初始化
public Node(Node next){
this.next=next;
}
//一般结点初始化
public Node(int data,Node next){
th...
分类:
编程语言 时间:
2014-11-22 09:17:42
阅读次数:
180
合并两个有序数组,放在A中,A中的空间足够。Given two sorted integer arrays A and B, merge B into A as one sorted array.Note:You may assume that A has enough space (size th...
分类:
其他好文 时间:
2014-11-22 01:56:43
阅读次数:
209
/* 样式重置 */body,h1,h2,h3,h4,h5,h6,p,dl,dd,ul,ol,form,input,textarea,th,td,select{ margin:0; padding:0;}em{ font:normal;}a{ text-decoration:none;}li{ li...
分类:
Web程序 时间:
2014-11-22 00:40:28
阅读次数:
290
Problem F: Fabled Rooks
We would like to place
n rooks, 1 ≤ n ≤ 5000, on a n×n board subject to the following restrictions
The i-th rook can only be placed within the rectangle given by its l...
分类:
其他好文 时间:
2014-11-21 23:23:27
阅读次数:
308
[转载]一篇还算可以的文章,关于可持久化线段树http://finaltheory.info/?p=249无修改的区间第K大我们先考虑简化的问题:我们要询问整个区间内的第K大。这样我们对值域建线段树,每个节点记录这个区间所包含的元素个数,建树和查询时的区间范围用递归参数传递,然后用二叉查找树的询问方...
分类:
其他好文 时间:
2014-11-21 23:11:31
阅读次数:
290
The maximum product of sub-arrays in $[1, n]$ can be divided by 3 cases:A[n] is the maximum product of all sub-arrays in [1, n].The array which has th...
分类:
其他好文 时间:
2014-11-21 18:27:25
阅读次数:
243
概述Unlike TCP, UDP has no notion of connections. A UDP socket can receive datagrams from any server on the network and send datagrams to any host on th...
分类:
其他好文 时间:
2014-11-21 18:08:38
阅读次数:
447