//基于顺序表实现的简易通讯录-----1
#define_CRT_SECURE_NO_WARNINGS1
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
typedefstructstu//定义一个学生信息的结构体类型
{
charname[20];
charsex[6];
intage;
chartele[20];
charaddress[..
分类:
其他好文 时间:
2016-05-09 14:26:59
阅读次数:
257
//配置文件读写项目 #define _CRT_SECURE_NO_WARNINGS #include<stdio.h> #include<stdlib.h> #include<string.h> int writefile(const char *path/*in*/, char *pkey/*i ...
分类:
编程语言 时间:
2016-05-02 17:03:23
阅读次数:
482
#define_CRT_SECURE_NO_WARNINGS1
#include<iostream>
usingnamespacestd;
#include<assert.h>
#defineMAXSIZE100
typedefintDataType;
typedefstructSeqList
{
DataType_array[MAXSIZE];
size_t_size;
}SeqList;
voidInitSeqList(SeqList*pSeq)
{
assert(pS..
分类:
编程语言 时间:
2016-05-01 17:52:59
阅读次数:
350
二叉树:二叉树是一棵特殊的树,二叉树每个节点最多有两个孩子结点,分别称为左孩子和右孩子。#define_CRT_SECURE_NO_WARNINGS1#include<iostream>
#include<assert.h>
#include<stack>
#include<queue>usingnamespacestd;
//节点结构
template<clas..
分类:
其他好文 时间:
2016-04-27 19:03:00
阅读次数:
236
建立PriorityQueue.hpp:#define_CRT_SECURE_NO_WARNINGS1
#include<iostream>
usingnamespacestd;
#include<assert.h>
#include<vector>
template<classT>
structLess
{
booloperator()(constT&l,constT&r)
{
returnl<r;
}
};
template..
分类:
其他好文 时间:
2016-04-27 07:09:59
阅读次数:
181
#define_CRT_SECURE_NO_WARNINGS1
#include<iostream>
usingnamespacestd;
enumPointerTag{THREAD,LINK};//枚举
前言:为了遍历的方便,我们在二叉树中引入前驱和后序,这样就储存了相关信息。
其结构如下:template<classT>
structBinaryTreeThdNode
{
T_data;..
分类:
其他好文 时间:
2016-04-27 07:09:56
阅读次数:
132
遇到比较多的数据时,我们通常采用"打擂台"的方法处理#define_CRT_SECURE_NO_WARNINGS1#include<stdio.h>intmain(){ inta,b,c,d,max; scanf("%d%d%d%d",&a,&b,&c,&d); max=a; if(b>max) max=b; if(c>max) max=c; if(d>max) max=d; printf("%..
分类:
其他好文 时间:
2016-04-23 15:09:27
阅读次数:
155
//函数声明:
#define_CRT_SECURE_NO_WARNINGS1
#include<stdio.h>
#include<stdlib.h>
#defineSTACK_INIT_MEMORY100
#defineSTACK_GROW_MEMORY10
typedefintElemType;
typedefstructstack
{
ElemType*esp;
ElemType*ebp;
intsize;//记录当前栈内空间最多能存几..
分类:
其他好文 时间:
2016-04-23 15:08:10
阅读次数:
173
本文摘自csdn沧海一粟的专栏 link:http://blog.csdn.net/xuleilx/article/details/7281499 Warning 1 warning C4996: 'fopen': This function or variable may be unsafe. C ...
分类:
其他好文 时间:
2016-04-22 11:58:01
阅读次数:
117
广义表是非线性的结构,是线性表的一种扩展,是有n个元素组成有限序列。
广义表的定义是递归的,因为在表的描述中又得到了表,允许表中有表#define_CRT_SECURE_NO_WARNINGS1
#include<iostream>
usingnamespacestd;
#include<assert.h>
enumType
{
HEAD,//头节点
..
分类:
其他好文 时间:
2016-04-22 10:44:06
阅读次数:
210