码迷,mamicode.com
首页 >  
搜索关键字:include    ( 84546个结果
BZOJ 2783 JLOI 2012 树 乘+二分法
标题效果:鉴于一棵树和一个整数s,问中有树木几个这样的路径,点和担保路径==s,深度增量点。这一数额的输出。思维:用加倍的想法,我们可以O(logn)在时间找点他第一n。因为点权仅仅能是正的,满足二分性质。然后对于每个点二分。看看有没有路径的权值和是S。统计答案,输出。CODE:#include #...
分类:其他好文   时间:2015-07-24 20:43:46    阅读次数:99
Hat’s Words hdu-1247
就是查找这个单词能不能有两个单词组成,简单的字典树题目//////////////////////////////////////////////////////////////#include#include#includeusingnamespacestd;#definemaxn26struct...
分类:其他好文   时间:2015-07-24 20:43:00    阅读次数:116
c语言字符串处理
1)c语言字符串:#include #include int main(int argc, char *argv[]) { char ch[] = {'a', 'b', 'c', '\0'}; char ch1[] = {'x', 'y', 'z'}; printf("%s\n", ch1);...
分类:编程语言   时间:2015-07-24 20:38:59    阅读次数:129
B - Networking - poj 1287
有一些地方需要铺盖电缆,这些地方两点间的路可能不止一条,需要求出来至少需要多少电缆才能让所有的点都连接起来,当然,间接连接也算。/////////////////////////////////////////////////////////////////////////#include#incl...
分类:Web程序   时间:2015-07-24 20:37:52    阅读次数:115
链表的翻转与排序
面试中常常会考到链表的翻转和排序,在此手动实现了一发,希望能对大家产生帮助#include using namespace std;templatestruct Node{ Node* pNext; T val;};templatevoid append(Node* head,T val...
分类:编程语言   时间:2015-07-24 20:34:41    阅读次数:130
Ubuntu使用Windows下的conio.h
把虚线框里面的内容粘贴进文档文本里面----------------------------------------------------------------------------------------------------------#include #include static s...
分类:Windows程序   时间:2015-07-24 20:30:40    阅读次数:146
OC面向对象和小知识点
oc小知识点:在c语言中汉子占三个字节oc中汉子和字符都是一个字节#include 和 #import 区别wimport 可以防止重复包含Foundation 把oc的库文件都包含过来@autoreleasepool 自动释放池NSLog 会自动换行NSLog 会自动输出时间项目信息NSLog 传...
分类:其他好文   时间:2015-07-24 20:28:43    阅读次数:98
高精度运算(大数)
求模(mod):直接在草稿纸上用小学方法算除法就能看出来 1 #include 2 #include 3 char m[1010]; 4 int main(){int n,temp; 5 while(~scanf("%s %d",m,&n)){temp=0; 6 for(in...
分类:其他好文   时间:2015-07-24 20:17:16    阅读次数:91
Most Powerful(ZOJ 3471状压dp)
题意:n个原子,两两相撞其中一个消失,产生能量,给出任意两原子相撞能产生的能量,求能产生的最大能量。分析:dp[i]表示情况为i时产生的最大能量/*#include #include #include #include #include #include #include #include #inc...
分类:其他好文   时间:2015-07-24 20:15:16    阅读次数:95
几道水题(18岁的生日,空心三角形)
18岁的生日: 1 #include 2 int m[13]={31,28,31,30,31,30,31,31,30,31,30,31}; 3 int nian(int x){ 4 if(x%400==0||(x%4==0&&x%100!=0))return 1; 5 else re...
分类:其他好文   时间:2015-07-24 20:14:36    阅读次数:127
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!