随笔分类 - 程序模块
摘要:http://blog.csdn.net/hackbuteer1/article/details/6595881#include #include #include #include using namespace std;#define MAXN 9999#define MAXSIZE 10#de...
阅读全文
摘要:#includeusing namespace std;#define INF 0x7fffffff#define N 10000// O(n^2)int len[N];int dp(int *a, int n){ int mx = 0, mxlen = 1; for (int i = ...
阅读全文
摘要:#define _CRT_SECURE_NO_WARNINGS#include#include#includeusing namespace std;#define BITMAX 1002 //数组大小typedef int valueType; //元素类型定义valueTyp...
阅读全文
摘要:#define _CRT_SECURE_NO_WARNINGS#include#includeusing namespace std;#define BITMAX 50001 //数组大小typedef int valueType; //元素类型定义valueType BITre...
阅读全文
摘要:输入一系列字符串构成trie树 T ,空行,再输入字符串,查询 T 中以这些字符串为前缀的字符串数量。通过修改插入时,对 count 的操作,可以实现很多变形功能。杭电1251,1671#include#include#include#includeusing namespace std;#defi...
阅读全文
摘要:#include#include#include#include#includeusing namespace std;/*void insertTree(BSTNode* &root, keyType val); //插入值 valvoid deleteTree(BSTNode* &root...
阅读全文
摘要:全部函数通过杭电 1142,1162,1198,1213等题目测试。#include#include#include#include#include#include#includeusing namespace std;/*//函数集合声明下,方便查看void Dijkstra(const dens...
阅读全文
摘要:全部函数通过杭电 1142,1162,1198,1213等题目测试。#include#include#include#include#include#include#includeusing namespace std;/*//函数集合声明下,方便查看void Dijkstra(const dens...
阅读全文