2015年8月8日

C语言接口与实现学习笔记——链表

摘要: 实现一个链表的一系列接口,体会了指针的用法list.h#ifndef LIST_INCLUDE#define LIST_INCLUDE#define T List_Ttypedef struct T *T;struct T{ T rest; void *first;};extern T ... 阅读全文

posted @ 2015-08-08 15:35 FrankieYe 阅读(290) 评论(0) 推荐(0)

2015年6月10日

poj1276

摘要: http://poj.org/problem?id=1276Cash MachineTime Limit:1000MSMemory Limit:10000KTotal Submissions:29234Accepted:10482DescriptionA Bank plans to install ... 阅读全文

posted @ 2015-06-10 20:39 FrankieYe 阅读(191) 评论(0) 推荐(0)

poj1191

摘要: http://poj.org/problem?id=1191棋盘分割Time Limit:1000MSMemory Limit:10000KTotal Submissions:12951Accepted:4612Description将一个8*8的棋盘进行如下分割:将原棋盘割下一块矩形棋盘并使剩下部... 阅读全文

posted @ 2015-06-10 09:42 FrankieYe 阅读(227) 评论(0) 推荐(0)

2015年6月2日

POJ3181

摘要: http://poj.org/problem?id=3181Dollar DayzTime Limit: 1000MS Memory Limit: 65536K Total Submissions: 910 Accepted: 339 DescriptionFarmer John goes to... 阅读全文

posted @ 2015-06-02 18:30 FrankieYe 阅读(182) 评论(0) 推荐(0)

2015年5月27日

最大子段和问题

摘要: 1、很容易想到的算法,复杂度为o(n^2) 1 int MaxSegSum1(int n, int *ans) 2 { 3 int sum = 0; 4 5 for(int i = 1; i 0 ? ans[left] : 0; 8 } 9 else10 ... 阅读全文

posted @ 2015-05-27 08:25 FrankieYe 阅读(289) 评论(0) 推荐(0)

2015年5月16日

KMP模式匹配

摘要: KMP的具体算法讲解可以参考此博文http://blog.csdn.net/v_july_v/article/details/7041827KMP算法的应用http://poj.org/problem?id=2406首先求得next数组若基础字符串为t,输入字符串为s,若s=t^n;那么下面的等式必... 阅读全文

posted @ 2015-05-16 16:58 FrankieYe 阅读(108) 评论(0) 推荐(0)

POJ1850

摘要: http://poj.org/problem?id=1850CodeTime Limit:1000MSMemory Limit:30000KTotal Submissions:8593Accepted:4079DescriptionTransmitting and memorizing inform... 阅读全文

posted @ 2015-05-16 16:40 FrankieYe 阅读(116) 评论(0) 推荐(0)

2015年5月14日

二分图匹配

摘要: http://poj.org/problem?id=1469匈牙利算法邻接矩阵版 1 #include 2 #include 3 #include 4 using namespace std; 5 6 const int maxNodes = 405; 7 8 int G[110][310... 阅读全文

posted @ 2015-05-14 21:35 FrankieYe 阅读(113) 评论(0) 推荐(0)

导航