DNA Sequencing
A DNA molecule consists of two strands that wrap around each other to resemble a twisted ladder whose sides, made of sugar and phosphate molecules, are connected by rungs of...
分类:
编程语言 时间:
2015-08-27 00:28:26
阅读次数:
199
Life Forms
Time Limit: 5000MS
Memory Limit: 65536K
Total Submissions: 11178
Accepted: 3085
Description
You may have wondered why most extraterrestrial life forms rese...
分类:
编程语言 时间:
2015-08-26 17:54:25
阅读次数:
155
Common Substrings
Time Limit: 5000MS
Memory Limit: 65536K
Total Submissions: 8471
Accepted: 2798
Description
A substring of a string T is defined as:
T(i, k)=TiTi+...
分类:
编程语言 时间:
2015-08-25 21:57:13
阅读次数:
172
最长公共子序列:
例如:abcfbc
abfcb 答案是:4;
最长公共子串 :答案是: 2;
代码:
最长公共子序列:
#include
#include
#define max(x,y) (x>y?x:y)
int len1,len2;
int dp[1010][1010];
int bj[1010...
分类:
其他好文 时间:
2015-08-21 11:21:57
阅读次数:
155
1 //比较两个字符串大小 2 bool compareSub(char* const s1,char* const s2) 3 { 4 int i=0; 5 while((itoupper(s2[i]))10 return false;11 ...
分类:
其他好文 时间:
2015-08-20 15:11:48
阅读次数:
93
字符串问题
1.左旋问题
2.字符包含问题
3.字符匹配KMP
4.编辑距离
5.最大回文子串,公共子串
6.最大公共子序列,回文子序列,上升子序列
7.基本字符串函数实现
8.大整数的加,减,乘,除,模
9.合法回文,数字串
10.正则匹配,最长公共前缀,简化路经
1) 左旋字符串
定义字符串的左旋转操作:把字符串前面的若干个字符移动到字符串的尾部,如把字符串ab...
分类:
其他好文 时间:
2015-08-20 06:48:58
阅读次数:
385
import java.util.Scanner;
public class GetCommonStr {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
String str1 = scan.nextLine();
String str2 = scan.nextLi...
分类:
其他好文 时间:
2015-08-19 23:49:10
阅读次数:
188
1.原题是求出最大公共子串的个数即可
原理:利用二维矩阵排列的方式,将俩字符串进行比较
#include
#include
using namespace std;
int prcs_2Strs(const char* s1,const char* s2)
{
int maxSameLength = 0;
int L1 = strlen(s1);
int L2 = strlen(...
分类:
其他好文 时间:
2015-08-18 19:28:14
阅读次数:
146
Long Long Message
Time Limit: 4000MS
Memory Limit: 131072K
Total Submissions: 23696
Accepted: 9705
Case Time Limit: 1000MS
Description
The little cat is majoring i...
分类:
编程语言 时间:
2015-08-18 19:25:21
阅读次数:
123
最长公共子序列,英文缩写为LCS(Longest Common Subsequence)。其定义是,一个序列 S ,如果分别是两个或多个已知序列的子序列,且是所有符合此条件序列中最长的,则 S 称为已知序列的最长公共子序列。而最长公共子串(要求连续)和最长公共子序列是不同的。
#include "stdafx.h"
#include
#include
using names...
分类:
其他好文 时间:
2015-08-17 19:34:36
阅读次数:
116