![](https://img-blog.csdnimg.cn/20190918140145169.png?x-oss-process=image/resize,m_fixed,h_224,w_224)
算法&设计模式
文章平均质量分 72
数据结构和常用软件设计模式
Chester_Carson
每天进步一点点
展开
-
数据结构中常用排序算法:插入/冒泡/选择/快速排序法(C示例)
前言:本章针对工作中比较常用的几种排序算法进行了总结,主要有直接插入排序,冒泡排序,简单选择排序以及快速排序四种算法,从算法基本思想,各种排序的过程示意图,代码示例,最后再分析了算法的空间,时间复杂度以及稳定性,本文C代码示例经过测试,可以使用,如果需要获取全面的demo可以通过git 仓库获取https://github.com/github-mcchen/sort/tree/develop...原创 2020-01-05 16:34:23 · 835 阅读 · 0 评论 -
CRC8校验
#include <stdio.h>#include <string.h>typedef struct{ unsigned char poly;//多项式X8+X2+X+1/X8+X5+X4+1 unsigned char InitValue;//算法开始时寄存器(crc)的初始化预置值 unsigned char xor;//计算结果与此参数异或后得到最终...原创 2019-12-11 22:19:07 · 825 阅读 · 0 评论 -
单向链表反转
#include <stdio.h>#include <stdlib.h>typedef struct Node{ struct Node* next; int data;}*LinkList, Node;LinkList List = NULL;int InitList(LinkList *L){ *L = (LinkList)malloc(s...原创 2019-11-28 23:15:09 · 129 阅读 · 0 评论 -
通过C语言实现#软件设计模式#观察者模式
观察者模式定义:当对象间的一种一对多的依赖关系,当一个对象的状态发生改变时,所有依赖于它的对象都得到通知并自动更新,也可以称这种模式发布-订阅模式原创 2020-03-15 13:55:17 · 374 阅读 · 2 评论