码迷,mamicode.com
首页 >  
搜索关键字:typedef struct    ( 24378个结果
最大流ISAP算法模板
这两天学习了网络流,下面是ISAP算法模板: const int inf = 0x3fffffff; template struct Isap { int top; int d[N], pre[N], cur[N], gap[N]; struct Vertex{ int head; } V[N]; struct Edge{...
分类:其他好文   时间:2014-05-26 04:10:16    阅读次数:252
第九周编程作业
A:list总时间限制:4000ms内存限制:65536kB描写叙述写一个程序完毕下面命令:new id ——新建一个指定编号为id的序列(id#include #include #include using namespace std;typedef map > Map;int main(){ i...
分类:其他好文   时间:2014-05-26 02:26:51    阅读次数:337
Queue2
1 #include 2 using namespace std; 3 template 4 class Queue 5 { 6 private: 7 struct node 8 { 9 T data;10 node * next;11 ...
分类:其他好文   时间:2014-05-26 02:19:36    阅读次数:213
线段交点模版
http://acm.hdu.edu.cn/showproblem.php?pid=1086跨立实验算法#include#include#include#includeusing namespace std;struct Point{ double x,y;} ;struct Line{ ...
分类:其他好文   时间:2014-05-26 02:10:52    阅读次数:224
c语言线性表
c语言的线性表,还没有完善 1 #include 2 #define MAXSIZE 100 //初始空间分配量 3 #define OK 1 4 #define ERROR 0 5 #define TRUE 1 6 #define FALSE 1 7 typedef int ElemTyp...
分类:编程语言   时间:2014-05-26 00:26:39    阅读次数:339
typedef与define 傻傻的分不清楚
今天看到 typedef与define的区别 上网搜了一下 总结一下 大部分内容出自百度知道,自己理解后又添了点。如发现不对,留言,大家一起研究一下typedef int * pint ; #define PINT int * 那么: const pint p ;//p不可更改,但p指向的内容可更改...
分类:其他好文   时间:2014-05-25 19:38:52    阅读次数:283
hdu 3629 Convex(计数问题)
题目链接:hdu 3269 Convex 题目大意:给出n个点,问任选四个点可以组成多少个凸四边形。 解题思路:和uav11529的做法是一样的,只不过求的东西不一样。 #include #include #include #include #include using namespace std; typedef long long ll; const int N =...
分类:其他好文   时间:2014-05-25 18:38:17    阅读次数:155
看书小记9(《C专家编程》)
哈希表简单实现,练个手 #include "stdafx.h" #include using namespace std; #define HASHSIZE 12 typedef struct HashTable { int *elem; int count; }HashTable; int m = 0; void Print(HashTable* ...
分类:其他好文   时间:2014-05-25 07:02:06    阅读次数:169
UVA 11624 UVA 10047 两道用 BFS进行最短路搜索的题
很少用bfs进行最短路搜索,实际BFS有时候挺方便得,省去了建图以及复杂度也降低了O(N*M);UVA 11624 写的比较挫#include #include #include #include using namespace std;struct node{ int ft; int ...
分类:其他好文   时间:2014-05-25 03:23:54    阅读次数:210
POJ - 1077 Eight
题意:经典八数码问题 思路:HASH+BFS#include #include #include #include using namespace std; const int MAXN = 500000; const int size = 1000003; typedef int State[9]; char str[30]; int state[9],goal[9]={1, 2, ...
分类:其他好文   时间:2014-05-24 21:46:23    阅读次数:359
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!