码迷,mamicode.com
首页 >  
搜索关键字:struct enum    ( 22969个结果
iOS/object-c: 枚举类型 enum,NS_ENUM,NS_OPTIONS
一般情况下,我们采用C风格的enum关键字可以定义枚举类型。[cpp]view plaincopyenum{UIViewAnimationTransitionNone,UIViewAnimationTransitionFlipFromLeft,UIViewAnimationTransitionFli...
分类:移动开发   时间:2014-08-03 22:56:16    阅读次数:278
kruskal 算法模板
http://acm.sdut.edu.cn/sdutoj/problem.php?action=showproblem&problemid=2896#include #include #include struct node{ int u,v,w;}q[200001];int bin[500...
分类:其他好文   时间:2014-08-03 22:49:36    阅读次数:172
连接不上
#include#include#include#include#include#includeint main(){ int server_sockfd,client_sockfd; int server_len,client_len; struct sockaddr_in se...
分类:其他好文   时间:2014-08-03 18:00:35    阅读次数:208
POJ 3348
旋 转卡壳水题。直接使用旋转卡壳求距离。#include #include #include #include #include using namespace std;const int MAXN=50100;struct point { int x,y;}p[MAXN];int n;int st...
分类:其他好文   时间:2014-08-03 17:36:05    阅读次数:227
结构体指针内存——指针数组——字符串指针内存申请
前几天用的结构体,结构体内还包含有结构体指针和数组以及指向字符串的指针,发现自己对这方面的东西还很容易犯错,故现在讲其中容易出错的地方写出来,分享给大家也方便自己日后查看。 typedef struct { char name[50]; char job[50]; int age; int people_id; } peopleInfo; typedef struct...
分类:其他好文   时间:2014-08-03 15:21:35    阅读次数:190
Redis实现原理(2)--字典
1、 Dict2.1 数据结构定义dict.h// 哈希表结构typedef struct dictht { dictEntry **table; //哈希表数组指针 unsigned long size; //哈希表大小 unsigned long sizemask; //掩码...
分类:其他好文   时间:2014-08-03 15:11:05    阅读次数:193
Linux内核剖析 之 进程地址空间(二)
//接前一章,本节主要介绍线性区以及相关线性区的操作。 线性区 Linux通过类型为vm_area_struct的对象实现线性区。 vm_area_struct: struct vm_area_struct { struct mm_struct * vm_mm; /* The address space we belong to. */ unsigned long vm_start...
分类:系统相关   时间:2014-08-03 10:21:55    阅读次数:497
优先队列
#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; struct node{ char...
分类:其他好文   时间:2014-08-03 10:20:25    阅读次数:216
poj 1456 Supermarket (贪心+并查集)
# include # include # include using namespace std; int fa[10010]; struct node { int p; int d; }; struct node a[10010]; bool cmp(node a1,node a2)//利润从大到小 { return a1.p>a2.p; } int find(int x) {...
分类:其他好文   时间:2014-08-03 10:16:25    阅读次数:208
Populating Next Right Pointers in Each Node
问题:将二叉树的所有结点指向他的右边的一个结点分析:对于每一个结点来说,其操作都是一样的,除了他的左儿子指向右儿子外,其左儿子的全部右后辈均指向其右儿子的全部左后辈/** * Definition for binary tree with next pointer. * struct TreeLin...
分类:其他好文   时间:2014-08-03 10:12:05    阅读次数:178
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!