码迷,mamicode.com
首页 >  
搜索关键字:suffix automaton    ( 461个结果
POJ3150---Cellular Automaton(矩阵)
DescriptionA cellular automaton is a collection of cells on a grid of specified shape that evolves through a number of discrete time steps according to a set of rules that describe the new state of a c...
分类:其他好文   时间:2015-03-17 21:52:30    阅读次数:130
php字符串读取函数
function cc_msubstr($str, $length, $start=0, $charset="utf-8", $suffix=true){ if(function_exists("mb_substr")){ return mb_substr($st...
分类:Web程序   时间:2015-03-17 19:32:08    阅读次数:151
bzoj 2251
第一道后缀数组后缀数组要维护三个数组:sa(suffix array), rk(rank)和ht(height)。含义分别是:sa[i]:将后缀按照字典序排序后,第i大的后缀的起始位置。rk[i]:起始位置为i的后缀的排名。ht[i]:起始位置为i的后缀与排名为rk[i]-1的后缀的最长公共前缀。对...
分类:其他好文   时间:2015-03-17 17:40:39    阅读次数:149
LA 3704 (矩阵快速幂 循环矩阵) Cellular Automaton
将这n个格子看做一个向量,每次操作都是一次线性组合,即vn+1 = Avn,所求答案为Akv0A是一个n*n的矩阵,比如当n=5,d=1的时候:不难发现,A是个循环矩阵,也就是将某一行所有元素统一向右移动一位便得到下一行。而且循环矩阵相乘仍然是循环矩阵,所以只要求出Ak的第一行就行了。 1 #inc...
分类:其他好文   时间:2015-03-14 15:15:59    阅读次数:176
Deleting and Adding CRS resource
添加ora.OCRVOTE.dg资源:[root@rac1grid]#bin/crsctlstatresora.CRS.dg-pNAME=ora.CRS.dgTYPE=ora.diskgroup.typeACL=owner:grid:rwx,pgrp:oinstall:rwx,other::r--ACTION_FAILURE_TEMPLATE=ACTION_SCRIPT=AGENT_FILENAME=%CRS_HOME%/bin/oraagent%CRS_EXE_SUFFIX%ALIAS_NAME=..
分类:其他好文   时间:2015-03-11 19:56:30    阅读次数:154
日志切割|程序数据库备份
日志切割#!/bin/bash #cutnginxlogs nginx_sbin="/usr/local/openresty/nginx/sbin/nginx" log_files_path="/usr/local/openresty/nginx/logs" cut_log_files_dir="/data/logs" logfilename_array=(www.bbs.com) date=`date+%Y-%m-%d-d"1daysago"` suffix=".log.gz" ProjectNam..
分类:数据库   时间:2015-03-10 19:44:32    阅读次数:458
thinkphp内置截取字符串函数无法显示省略号解决方法
thinkphp内置截取字符串函数无法显示省略号解决方法functions.phpfunction msubstr($str, $start=0, $length, $charset="utf-8", $suffix=true){ if(function_exists("mb_substr")) {...
分类:Web程序   时间:2015-03-07 00:56:46    阅读次数:564
1032. Sharing (25)
To store English words, one method is to use linked lists and store a word letter by letter. To save some space, we may let the words share the same sublist if they share the same suffix. For example,...
分类:其他好文   时间:2015-03-03 18:41:39    阅读次数:140
LZW压缩算法
介绍 LZW算法是非常常见的一种压缩算法,他的压缩原理是对于多次重复出现的字符串,进行压缩,至于怎么压缩,在后文中会细细描述,LZW算法可以用在很多的场合,诸如图像压缩,文本压缩等等,而且算法简单易懂,并不是人们想象中的那么深奥。 算法原理 在介绍算法原理之前,得先明白几个概念: 1、Prefix,在这里代表前缀字符的意思。 2、Suffix,对应的意思是后缀字符的意思。 为什么提到这...
分类:编程语言   时间:2015-02-27 21:41:07    阅读次数:272
[算法系列之二十四]后缀树(Suffix Tree)
之前有篇文章([算法系列之二十]字典树(Trie))我们详细的介绍了字典树。有了这些基础我们就能更好的理解后缀树了。一 引言 模式匹配问题给定一个文本text[0…n-1], 和一个模式串 pattern[0…m-1],写一个函数 search(char pattern[], char text[]), 打印出pattern在text中出现的所有位置(n > m)。这个问题已经有两个经典的算法:...
分类:编程语言   时间:2015-02-27 20:16:41    阅读次数:192
461条   上一页 1 ... 34 35 36 37 38 ... 47 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!