大话数据结构
文章平均质量分 92
wenpi_linuxer
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
KMP算法-动态规划
核心 算法核心是回溯子串指针,回溯值从子串next数组找出。相比较朴素的字符串匹配算法,主串指针不再回溯,子串next数组由子串前缀后缀重复字母数量确定。 #include <stdio.h> #include <string.h> void get_next(char* T,int *next){ int i,j; i=1; j=0; ne...原创 2020-03-14 23:52:18 · 355 阅读 · 0 评论 -
朴素的字符串匹配算法
#include <stdio.h> #include <string.h> int Index(char* s,char* t,int pos){ int i=pos; int j=0; int len1=strlen(s); int len2=strlen(t); while(i<=len1 && j<...原创 2020-03-14 19:29:20 · 418 阅读 · 0 评论 -
循环队列-数组实现队列ADT
#include <stdio.h> #include <stdlib.h> #define MAXSIZE 100 typedef int QElemType; typedef int Status; #define OK 1 #define ERROR 0 typedef struct{ //结构体定义 QElemType...原创 2020-03-14 19:07:24 · 454 阅读 · 0 评论 -
斐波那契数列-了解递归思想
递归 老实说递归有点慢,大量的递归调用会建立函数的副本,耗费大量的时间和内存,主要体现在栈空间的浪费 #include <stdio.h> int Fbi(int i){ if(i<2){ return i==0?0:1; } return Fbi(i-1)+Fbi(i-2); } int main(void){ int i; ...原创 2020-03-14 18:23:22 · 230 阅读 · 0 评论 -
大话数据结构-链栈ADT实现
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #define MAXSIZE 100 typedef int SElemType; typedef int Status; #define ERROR 0 #define TRUE 1 #define OK 1 #define FALSE 0...原创 2020-03-14 17:47:38 · 224 阅读 · 0 评论 -
大话数据结构-数组结构栈的实现
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #define MAXSIZE 100 typedef int SElemType; typedef int Status; #define ERROR 0 #define TRUE 1 #define OK 1 #define FALSE ...原创 2020-03-14 13:52:23 · 324 阅读 · 0 评论 -
重刷大话数据结构-单链表ADT实现
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <time.h> #define OK 1 #define ERROR 0 #define TRUE 1 #define FALSE 0 typedef int Status; //状态 type...原创 2020-03-14 12:36:23 · 212 阅读 · 0 评论
分享