C#中标准数据结构和算法的即插即用类库项目

GitHub:https://github.com/aalhour/C-Sharp-Algorithms

Watch: 307 Star: 3.4k Fork: 910

                                      o---o    |   |
/ --O---O--
O | |
\ --O---O--
o---o | | O o o--o o--o o---o o-O-o o--O--o o o o o o--o
/ \ | o o o | | | | | | |\ /| |
o---o | | o-o | | O--Oo | | O---O | \o/ | o--o
| | | o | o o | \ | | | | | | |
o o O---o o--o o--o o \o o-O-o o o o o o o---o

什么是C# 算法

标准数据结构和算法的即插即用类库项目,使用C#编写。它包含75多种数据结构和算法,被设计为面向对象的隔离组件。即使该项目出于教育目的而开始,但已实现的数据结构和算法都是标准、高效、稳定和经过测试的。

背后的故事

该项目最初是作为面试准备项目开始的。但是,在收到有关reddit的大量积极响应,并注意到一些GitHubers为它做出进一步贡献而感到兴奋之后,该项目的含义有所不同。因此,我决定继续对其进行维护,以作为C#中数据结构和算法实现以及这些主题下我自己的研究副项目的参考。

描述

解决方案层次结构

这是一个C#.NET解决方案,它包含三个子项目:

  1. Algorithms: 一个类库项目。包含算法实现
  2. Data Structures: 一个类库项目。包含数据结构实现
  3. UnitTest:对算法和数据结构实现的测试项目

要求

  1. .NET Core>=2.0
  2. XUnit

投稿者须知

如果你想为C#算法做出共享,请确保你首先查看贡献准则

数据结构

Linear:

  • Skip List
  • Array List
  • Stack
  • Queue
  • Single-Linked List
  • Double-Linked List

Circlar:

  • Circular Buffer

Heaps:

  • Binary-Min Heap
  • Binary-Max Heap
  • Binomial-Min Heap

Priority Queues:

  • Min-Priority Queue
  • Key-value Priority Queue

Hashing Functions:

  • Prime Hashing Family
  • Universal Hashing Family

Hash Tables:

  • Chained Hash Table
  • Cuckoo Hash Table
  • Open-Addressing Hash Table

Sorted Collections(Tree-based):

  • Sorted List
  • Sorted Dictionary

Trees:

  • Basic Search Trees:

    • Binary Search Tree

      • Map versions(Supports key-value pairing; nodes indexed by keys)
    • (Augmented) Binary Search Tree
    • Ternary Search Tree
  • Self-Balancing Trees:
    • AVL Tree
    • B-Tree
    • Red-Black Tree
      • Map version(supports key-value pairing;nodes indexed by keys)
  • Prefix Trees:
    • Trie
    • Trie Map (associative prefix tree;complete words are keys to records)

Graphs:

  • Undirected Graphs:

    • Clique Graphs
    • Undirected Sparse Graph
    • Undirected Dense Graph
  • Undirected Weighted Graphs:
    • Undirected Weighted Sparse Graph
    • Undirected Weighted Dense Graph
  • Directed Graphs:
    • Directed Sparse Graph
    • Directed Dense Graph
  • Directed Weighted Graphs:
    • Directed Weighted Sparse Graph
    • Directed Weighted Dense Graph

算法

排序算法(Sorting):

  • Bubble Sort
  • Bucket Sort
  • BST Sort
  • Comb Sort
  • Counting Sort
  • Cycle Sort
  • Gnome Sort
  • Heap Sort
  • Insertion Sort
  • LSD Radix Sort
  • Merge Sort
  • Selection Sort
  • Shell Sort
  • OddEven Sort
  • PigeonHole Sort
  • Quick Sort

Searching:

  • Binary Search

Graphs:

  • Graph Search:

    • Depth-Frist Searcher
    • Breadth-First Searcher
  • Shortest Paths:
    • Breadth-First SPs
    • Bellman-Ford SPs
    • Dijkstra SPs
    • Dijkstra All-Pairs SPs
  • DFS Applications:
    • Cycles Detector
    • Topological Sorter
  • BFS Applications:
    • Connected Components
    • Biparite Graphs Coloring

Tree:

  • Resursive Binary Tree Walker

    • Methods: PrintAll, ForEach, Contains and BinarySearch. Traversal Modes: Preorder, Inorder & Postorder

Strings:

  • Permutations and Anagrams
  • Edit Distance
    • Uses a generic custom class for passing costs: EditDistanceCostsMap

Numeric:

  • Binomial Coefficients
  • Catalan Numbers
  • Greatest Common Divisor

Visualization:

  • Tree Drawer

最新文章

  1. 更改vs自带的模板
  2. 【POJ】2234 Matches Game(博弈论)
  3. Android 查看webview里面的图片
  4. poj 3710 Christmas Game 博弈论
  5. UVa839 Not so Mobile
  6. 安装SQL Server提示“重叠的IO操作正在进行”解决
  7. poj1637Sightseeing tour(混合图欧拉回路)
  8. CodeForces 609C Load Balancing
  9. Linux 系统化学习系列文章总目录(持续更新中)
  10. Excel大批量数据导出
  11. 贝叶斯、朴素贝叶斯及调用spark官网 mllib NavieBayes示例
  12. MVC生成页码选择器返回HTML代码
  13. Shiro入门 - 通过ini文件进行认证
  14. 线程优先级.Priority()
  15. XML注释与取消注释快捷键
  16. WPF bind baidu Image
  17. MySQL主从检验一致性工具pt-table-checksum报错的案例分析
  18. Linux 批量查找替换方法(VIM和sed)
  19. python 面向对象 析构方法
  20. 557. Reverse Words in a String III

热门文章

  1. js利用cookie登录网站
  2. 一份从入门到精通NLP的完整指南 | NLPer
  3. VBScript 打开含有"空格"的路径 (Open Path with Space)
  4. Thread ---java 内存模型
  5. js函数基础回顾
  6. JAVA WEB随笔
  7. minIO分布式集群搭建+nginx负载均衡
  8. C 部落划分
  9. Pointer Lock API(1/3):Pointer Lock 的总体认识
  10. 查看手机wifi密码