码迷,mamicode.com
首页 >  
搜索关键字:include    ( 84546个结果
02两栈共享空间_DoubleStack--(栈与队列)
#include "stdio.h" #include "stdlib.h" #include "io.h" #include "math.h" #include "time.h"#define OK 1#define ERROR 0#define TRUE 1#define FALS...
分类:其他好文   时间:2015-06-06 17:52:39    阅读次数:131
1724: [Usaco2006 Nov]Fence Repair 切割木板( 贪心 )
倒过来看 , 每次总是选择最短的两块木板合并 , 用heap维护------------------------------------------------------------------------------#include#include#include#include#include...
分类:其他好文   时间:2015-06-06 17:52:28    阅读次数:124
暴力 Codeforces Round #183 (Div. 2) A. Pythagorean Theorem II
题目传送门 1 /* 2 暴力:O (n^2) 3 */ 4 #include 5 #include 6 #include 7 #include 8 #include 9 using namespace std;10 11 const int MAXN = 1e4 + 10;12 ...
分类:其他好文   时间:2015-06-06 17:50:45    阅读次数:125
输入一行统计其中单词的个数
#include #include int main(){ int count = 1; char str[1024]; int i=0; int j =0; char ch='0'; while(ch != '\n') //输入一串英文 { ...
分类:其他好文   时间:2015-06-06 17:49:38    阅读次数:99
06链队列_LinkQueue--(栈与队列)
#include "stdio.h" #include "stdlib.h" #include "io.h" #include "math.h" #include "time.h"#define OK 1#define ERROR 0#define TRUE 1#define FALS...
分类:其他好文   时间:2015-06-06 17:48:17    阅读次数:162
简单水题 POJ 2291 Rotten Ropes
题目传送门 1 /* 2 我校oj的源题,看懂题意就很水,贴出来省的再敲:) 3 */ 4 #include 5 #include 6 #include 7 using namespace std; 8 9 const int MAXN = 1e3 + 10;10 const int...
分类:其他好文   时间:2015-06-06 17:48:07    阅读次数:118
05顺序队列_Queue--(栈与队列)
#include "stdio.h" #include "stdlib.h" #include "io.h" #include "math.h" #include "time.h"#define OK 1#define ERROR 0#define TRUE 1#define FALS...
分类:其他好文   时间:2015-06-06 17:47:48    阅读次数:121
hdu 1085 Holding Bin-Laden Captive!(母函数)
代码:#include #include using namespace std; long long c1[8005],c2[8005]; int main() { int a[4]; a[1]=1; a[2]=2; a[3]=5; int n[4]; while(scanf("%d%d%d",&n[1],&n[2],&n[3])&&(n[1]...
分类:其他好文   时间:2015-06-06 16:41:18    阅读次数:163
Effective C++ 条款44
本节条款的标题是:将与参数无关的代码抽离templates学习本节条款首先需要明白一件事情,那就是模板实例化的过程会不会重复? 我们来举个例子:#include using namespace std;template T Try(T m) { return m; }int main() { Try(10); Try(1); }...
分类:编程语言   时间:2015-06-06 16:37:17    阅读次数:79
简单的内存对齐
#include //#include #pragma pack(8) struct A { char c; //1byte double d; //8byte short s; //2byte int i; //4byte }; int main() { A strua; printf("%d\n",sizeof(A)); printf("%d,%d,%d,%d\n"...
分类:其他好文   时间:2015-06-06 16:37:10    阅读次数:134
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!