Given two strings S and T, determine if they are both one edit distance apart. 这道题是之前那道Edit Distance的拓展,然而这道题并没有那道题难,这道题只让我们判断两个字符串的编辑距离是否为1,那么我们只需分下列
分类:
其他好文 时间:
2016-02-07 17:25:46
阅读次数:
214
ASSUME CS:CODE, DS:DATA ;ASSUME伪指令规定段的性质 X DW 4 ;定义第一个加数 用 MASM 6.11 和 CodeView 汇编和调试汇编语言程序 在 MASM 6.11 中,Microsoft 公司提供了程序员工作平台 PWB。这是一个集成化开发环境,程序员可以
分类:
其他好文 时间:
2016-02-07 17:23:33
阅读次数:
283
EN: It's easy to find out where is the bug : .text:0000000000400DE4 ; void *start_routine(void *).text:0000000000400DE4 start_routine proc near ; DATA
分类:
其他好文 时间:
2016-02-07 17:25:22
阅读次数:
253
题目大概问小于等于m个的物品放到n个地方有几种方法。 即解这个n元一次方程的非负整数解的个数$x_1+x_2+x_3+\dots+x_n=y$,其中0<=y<=m。 这个方程的非负整数解个数是个经典问题,可以+1转化正整数解的个数用插板法解决:$C_{y+n-1}^{n-1}=C_{y+n-1}^y
分类:
其他好文 时间:
2016-02-07 17:22:41
阅读次数:
202
题目链接:点击打开链接
题意:n个城市, m条可以修建的路, 修每条路有一个费用, 要求修建路将n个城市全部联通,并且最大费用减去最小费用最小。
思路:枚举最小边, 然后重新求一遍最小生成树,复杂度m^2, 出的数据水了, 左边BC水过了。。
细节参见代码:
#include
#include
#include
#include
#include
#include
#include
#in...
分类:
其他好文 时间:
2016-02-07 13:38:48
阅读次数:
209
SVN -- subversion ①checkout 拷贝svn资源库的内容②commit 开发完后,提交③update 得到其他人开发的资源 访问svn默认端口3690 安装 下载svn服务器软件http://subversion.apache.org/packages.html 安装Win32
分类:
其他好文 时间:
2016-02-07 13:40:11
阅读次数:
213
C函数库中有一个函数 strstr(char*, char*),它实现的是在一个原字符串中查找一个子串。假设找到这种一个子串,返回这个子串在原字符串中的起始位置,若没有找到这种一个子串。则返回NULL。 可是,函数库中实现的仅是普通情况下的查找。即没有做太多优化,在运行一些特殊的字符串时效率非常低,
分类:
其他好文 时间:
2016-02-07 13:39:02
阅读次数:
177
Description "Kronecker's Knumbers" is a little company that manufactures plastic digits for use in signs (theater marquees, gas station price displays
分类:
其他好文 时间:
2016-02-07 13:38:03
阅读次数:
251
因为明年的工作可能要涉及到加密的问题,所以要看一下加密方面,刚好之前对于web开发方面的加密,https也一直有疑问,于是就买了本图解密码技术来看看 1.如何保证数据只能单向解密: 比较流行的一个就是公钥和私钥,公钥负责加密,私钥负责解密,只要私钥没有被拿到,数据就不会被破解,比较流行的 就是RSA
分类:
其他好文 时间:
2016-02-07 13:37:20
阅读次数:
228
Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would be if it were inserted in or
分类:
其他好文 时间:
2016-02-07 13:35:12
阅读次数:
217
听别人说信息班应该用不同的方式来庆祝新年 哇咔咔! 那就只能以独特的方式庆祝咯……#include<cstdio>#include<cmath>#include<cstring>#include<iostream>#include<algorithm>#include<functional>#inc
分类:
其他好文 时间:
2016-02-07 13:35:33
阅读次数:
266
今天,我们要讲的是自定义jinja2 过滤器这个知识点,因为官方文档对此一代而过,讲得不够清楚,所以我们专门拿出来讲一下。 例子 例子写了两个自定义过滤器,一个是转换字典到字符串的过滤器,一个是返回当前参数的类型的过滤器。 源代码: https://github.com/lewis617/jinja
分类:
其他好文 时间:
2016-02-07 13:37:31
阅读次数:
1283
树形DP水题。判断取法是否唯一,dp的时候记录一下每个状态从下面的子节点推导过来的时候是否唯一即可。 #include<cstdio> #include<cstring> #include<cmath> #include<ctime> #include<map> #include<vector> #
分类:
其他好文 时间:
2016-02-07 13:35:43
阅读次数:
257
【HDU2222】 最纯粹的裸题,错误点详见注释。 1 #include<iostream> 2 #include<cstdio> 3 #include<cstring> 4 #include<algorithm> 5 #include<queue> 6 using namespace std; 7
分类:
其他好文 时间:
2016-02-07 13:36:30
阅读次数:
260
Financial Crisis 题意:给一个图,包含N ( 3 <= N <= 5000 )个点, M ( 0 <= M <= 10000 )条边 and Q ( 1 <= Q <= 1000 )次查询.查询:两个点是否是点-双连通; 点-双连通:两点至少存在两条"点不重复"的路径;简称双连通(b
分类:
其他好文 时间:
2016-02-07 13:34:17
阅读次数:
285
1、dos命令安装mysqld --stall、启动net start mysql、进入MySQL数据库mysql -uroot -p后,输入select user();当前用户 select current_date();当前日期 select current_time();当前时间 select
分类:
其他好文 时间:
2016-02-07 13:33:39
阅读次数:
159