码迷,mamicode.com
首页 >  
搜索关键字:struct enum    ( 22969个结果
Linux 内存池设计构想
一、基本数据结构 1 union m_block 2 { 3 union m_block* next; 4 unsigned int size; 5 }; 6 7 struct m_list 8 { 9 union m_block* free;...
分类:系统相关   时间:2014-06-19 07:59:56    阅读次数:309
二叉树
二叉树基本操作代码#include "stdafx.h"#include "stdlib.h"#include "string.h"#define MAX 100typedef char Elemtype;typedef struct BTNODE{ Elemtype data; BTN...
分类:其他好文   时间:2014-06-19 07:51:41    阅读次数:251
20天自制操作系统(八)
移动鼠标并显示鼠标坐标struct MOUSE_DEC { unsigned char buf[3], phase; int x, y, btn;}; enable_mouse(&mdec); for (;;) { io_cli(); //...
分类:其他好文   时间:2014-06-19 06:55:18    阅读次数:201
模板中的名字查找问题
##**问题起源**先看下面很简单的一小段程序。```cpp`#include ```````cpptemplate struct Base { void fun() { std::cout struct Derived : Base{ void gun() { ...
分类:其他好文   时间:2014-06-19 06:11:12    阅读次数:244
图的存储
#include#include#includeint k,h[110],mark;struct M{ int data; struct M *next;}*head[110];void init(){ int i; for(i = 0; i next = NULL; ...
分类:其他好文   时间:2014-06-17 00:58:16    阅读次数:315
Geeks 一般二叉树的LCA
不是BST,那么搜索两节点的LCA就复杂点了,因为节点是无序的。 下面是两种方法,都写进一个类里面了。 当然需要重复搜索的时候,可以使用线段树及多种方法加速搜索。 #include #include using namespace std; class LCANormalTree { struct Node { int key; Node *left, *right;...
分类:其他好文   时间:2014-06-16 20:20:04    阅读次数:234
关键字enum的用法
关键字enum的用法小结...
分类:其他好文   时间:2014-06-16 20:14:55    阅读次数:153
编程算法 - 数组构造二叉树并打印
数组构造二叉树并打印本文地址: http://blog.csdn.net/caroline_wendy数组:构造二叉树, 需要使用两个队列(queue), 保存子节点和父节点, 并进行交换;打印二叉树, 需要使用两个队列(queue), 依次打印父节点和子节点, 并进行交换;二叉树的数据结构:struct BinaryTreeNode { int m_nValue; BinaryTreeNod...
分类:其他好文   时间:2014-06-16 19:45:17    阅读次数:373
二叉树的应用(1)--二叉树排序树基本操作
#include struct BSTNode { int m_nval; //数据域 BSTNode *m_pleft; // 左孩子节点 BSTNode *m_pright; //右孩子节点 }; /************************************************************************ 功能:在二叉排序树中 查找key值,...
分类:其他好文   时间:2014-06-15 12:14:04    阅读次数:228
C++中关于指针运算符->的重载问题
#includeusing namespace std;struct date{int year;int month;int day;};struct Person{string name;int age;bool gender;double salary;date birth;Person(){c...
分类:编程语言   时间:2014-06-15 10:37:12    阅读次数:207
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!