悲伤逆流成河

大学上了两年了,在编程方面依然是一事无成,感觉很急躁,但又经常学不进去,尤其是进行上机试验,更是无心呀。
心情日记 | 2010-06-27 22:16 | 阅读 638 次 | 评论 0 条

循环队列

#include <stdio.h>#include <malloc.h>#define OK 1#define ERROR 0#define TRUE 1#define FALSE 0#define OVERFLOW -2typedef int Status;typedef int QElemType;#define MAXQSIZE 6typedef struct{ QElemType *base; int front; int rear;}SqQueue; Status InitQueue(SqQueue &amp;Q){ Q.base=(QElemType*)malloc(MA...

关键路径

//006.h #include <stdio.h>#include <stdlib.h>typedef int Status;typedef int SElemType; #define ERROR 0#define OK 1#define OVERFLOW -2#define STACK_INIT_SIZE 10#define STACKINCREMENT 2typedef struct { SElemType *base; SElemType *top; int stacksize;}SqStack; Status InitStack(SqStack &amp;S){ if(...

单链表

//007.h #include <stdio.h>#include <stdlib.h>#include <malloc.h> int over_flag=0; typedef int ElemType;typedef struct LNode{ ElemType data; struct LNode *next;}LNode,*LinkList; void Traverse(LinkList L);void CreateList(LinkList &amp;L);void exchange(LinkList &amp;L);void delete_even(LinkList ...

赫夫曼编码

# include <stdio.h> # include <stdlib.h># include <conio.h># include <string.h># define MAX_LENGTH 100typedef char **HuffmanCode;//**********数据结构*************typedef struct { int weight; //权值 int parent,lchild,rchild; //双亲,左右孩子}HTNode,*HuffmanTree; //结点和指针//**********select函数*******...
文章归档
最新评论