{"id":35847118,"url":"https://github.com/originalix/algorithm","last_synced_at":"2026-01-08T06:04:39.426Z","repository":{"id":20225704,"uuid":"88919407","full_name":"originalix/algorithm","owner":"originalix","description":"算法（第4版）TypeScript 实现","archived":false,"fork":false,"pushed_at":"2023-01-07T23:11:55.000Z","size":1543,"stargazers_count":16,"open_issues_count":6,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-14T21:47:01.637Z","etag":null,"topics":["algorithm"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/originalix.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-04-20T23:30:57.000Z","updated_at":"2024-03-16T09:23:20.000Z","dependencies_parsed_at":"2023-01-12T03:30:21.100Z","dependency_job_id":null,"html_url":"https://github.com/originalix/algorithm","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/originalix/algorithm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/originalix%2Falgorithm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/originalix%2Falgorithm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/originalix%2Falgorithm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/originalix%2Falgorithm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/originalix","download_url":"https://codeload.github.com/originalix/algorithm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/originalix%2Falgorithm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28242001,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2026-01-08T02:00:06.591Z","response_time":241,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithm"],"created_at":"2026-01-08T06:04:04.745Z","updated_at":"2026-01-08T06:04:39.417Z","avatar_url":"https://github.com/originalix.png","language":"TypeScript","readme":"# 算法（第4版）TypeScript 版本\n\n---\n\n本仓库包含了 TypeScript 描述的算法与数据结构。\n\n是我在阅读经典算法书籍《算法（第4版）》时完成的，记录自己的算法学习过程。\n\n## 使用方式\n\nInstall:\n\n```bash\nyarn\nnpm install\n```\n\nCompile:\n\n```bash\nyarn start\nnpm start\n```\n\nTest:\n\u003e 执行上述每个算法的单元测试用例\n\n```bash\nyarn test\nnpm run test\n```\n\n## 队列、链表、栈\n\n* [Dijkstra 的双栈算术表达式求值算法](src/algs4/1-3/evaluate.ts)\n* [队列(链表实现)](src/algs4/1-3/node-queue.ts)\n* [栈(链表实现)](src/algs4/1-3/node-stack.ts)\n* [动态调整大小的栈](src/algs4/1-3/resizing-array-stack.ts)\n\n## 并查集\n\n* [并查集](src/algs4/1-5/union-find.ts)\n* [并查集(树型森林的表示)](src/algs4/1-5/quick-union.ts)\n* [并查集(加权算法)](src/algs4/1-5/weight-quick-union.ts)\n\n## 排序\n\n* [插入排序](src/algs4/sort/insertion.ts)\n* [选择排序](src/algs4/sort/selection.ts)\n* [希尔排序](src/algs4/sort/shell-sort.ts)\n* [归并排序](src/algs4/sort/merge-sort.ts)\n* [快速排序](src/algs4/sort/quick-sort.ts)\n* [三指针快排](src/algs4/sort/quick3way.ts)\n* [优先队列(堆)](src/algs4/sort/max-pq.ts)\n* [堆排序](src/algs4/sort/heap-sort.ts)\n\n## 查找\n\n* [符号表 顺序查找(基于无序链表)](src/algs4/search/sequential-search-st.ts)\n* [符号表 二分查找(基于有序数组)](src/algs4/search/binary-search-st.ts)\n* [二叉查找树](src/algs4/search/binary-search-tree.ts)\n* [红黑树](src/algs4/search/red-black-bst.ts)\n\n## 图\n\n* [无向图(邻接表表示)](src/algs4/graph/graph.ts)\n* [DFS 深度优先搜索](src/algs4/graph/dfs.ts)\n* [BFS 广度优先搜索](src/algs4/graph/bfs.ts)\n* [连通分量](src/algs4/graph/connect-components.ts)\n* [符号图](src/algs4/graph/symbol-graph.ts)\n* [有向图](src/algs4/graph/digraph.ts)\n* [有向图的可达性](src/algs4/graph/directed-dfs.ts)\n* [有向图中深度优先搜索的顶点排序](src/algs4/graph/depth-first-order.ts)\n* [拓补排序](src/algs4/graph/topological.ts)\n* [有向图的强连通分量](src/algs4/graph/kosaraju.ts)\n* [最小生成树的 Prim 算法](src/algs4/graph/prim-mst.ts)\n* [最小生成树的 Kruskal 算法](src/algs4/graph/kruskal-mst.ts)\n* [最短路径 Dijkstra 算法](src/algs4/graph/dijkstra-sp.ts)\n* [无环加权有向图的最短路径算法](src/algs4/graph/acyclic-sp.ts)\n\n## 字符串\n\n* [LSD(低位优先的字符串排序)](src/algs4/strings/LSD.ts)\n* [基于单词查找树的符号表](src/algs4/strings/tries-st.ts)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foriginalix%2Falgorithm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foriginalix%2Falgorithm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foriginalix%2Falgorithm/lists"}