{"id":13672171,"url":"https://github.com/ninechapter-algorithm/leetcode-linghu-templete","last_synced_at":"2025-05-15T03:06:21.830Z","repository":{"id":37383743,"uuid":"288063370","full_name":"ninechapter-algorithm/leetcode-linghu-templete","owner":"ninechapter-algorithm","description":"算法面试必备，推荐刷题网站www.lintcode.com。北大学霸的《LeetCode刷题模板》+V领取: jiuzhangfeifei","archived":false,"fork":false,"pushed_at":"2022-09-08T07:48:36.000Z","size":8887,"stargazers_count":3299,"open_issues_count":4,"forks_count":782,"subscribers_count":79,"default_branch":"master","last_synced_at":"2025-05-04T09:02:07.720Z","etag":null,"topics":["algorithm","java","leetcode","python"],"latest_commit_sha":null,"homepage":"https://www.lintcode.com/?utm_source=github-jenny","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ninechapter-algorithm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-08-17T02:16:03.000Z","updated_at":"2025-04-24T11:34:38.000Z","dependencies_parsed_at":"2022-07-11T20:03:38.632Z","dependency_job_id":null,"html_url":"https://github.com/ninechapter-algorithm/leetcode-linghu-templete","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ninechapter-algorithm%2Fleetcode-linghu-templete","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ninechapter-algorithm%2Fleetcode-linghu-templete/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ninechapter-algorithm%2Fleetcode-linghu-templete/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ninechapter-algorithm%2Fleetcode-linghu-templete/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ninechapter-algorithm","download_url":"https://codeload.github.com/ninechapter-algorithm/leetcode-linghu-templete/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254264765,"owners_count":22041793,"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","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","java","leetcode","python"],"created_at":"2024-08-02T09:01:28.219Z","updated_at":"2025-05-15T03:06:17.246Z","avatar_url":"https://github.com/ninechapter-algorithm.png","language":null,"readme":"# 北大令狐冲的LeetCode算法小抄Cheatsheet\n首先自报家门，高中开始刷题，算法竞赛保送北大计算机学院，本硕连读毕业后，拿到网易、人人网、阿里、FB等公司offer，最终选择赴美国硅谷参加工作。到现在为止，刷过的算法题已超过**3000道**。\n\n废话不多说，直接上干货。祭出我爆肝3个月、增删16次的[《面试常考算法模板Cheatsheet》](https://github.com/ninechapter-algorithm/leetcode-linghu-templete/tree/master/%E4%BB%A4%E7%8B%90%E8%80%81%E5%B8%88%E7%9A%84%E7%AE%97%E6%B3%95%E5%B0%8F%E6%8A%84)，在本仓库第二个文档直接下载。\n\n这套《面试常考算法模板cheatsheet》，代码量不算少，案例也算不上牛逼，但绝对经典，绝对通用！像是二分、双指针、排序算法、二叉树、宽度优先搜索、深度优先搜索的使用条件、时间复杂度、代码模板，我也都整理好了。\n\n## 面试常考算法模板Cheatsheet的用法\n\n为了让大家能在我的Github得到尽可能多的帮助，这里献上使用方法：\n\n1、**先给本仓库点个star**，再背我总结的算法模板（模板都不想花时间背，就别继续看了）\n\n2、跟着下面目录中的的高频题练习（拿着模板练，一定要学会消化知识，这样才能举一反三）\n\n3、最后在[LintCode](https://www.lintcode.com/problem/?utm_source=sc-gihub-jw)找**大厂高频ladder**进行练习（别bb，拿着模板多刷题一定没错）\n \n## 我迭代了8年的算法学习课程-《九章算法班》\n\n2014年我到美国Facebook工作。在硅谷，我发现华人的求职压力特别大，面对很多来自白人、印度人的竞争。为了帮助更多的人能通过Google，Facebook，Ticktok等公司的算法面试，我总结了我10多年来的刷题经验，录制了一套只有9个章节、18小时的[《九章算法班》](https://www.jiuzhang.com/course/71/?utm_source=sc-github-jw)。如今8年过去了，这套课程已经迭代到了50个章节、100多小时，也有数十万的程序员学习过我的这套课程，并找到了年薪百万的工作。\n\n这套[《九章算法班》](https://www.jiuzhang.com/course/71/?utm_source=sc-github-jw)是收费的，但我也可以先看看我总结的免费的B站算法学习视频[《1个月刷爆LeetCode》](https://link.zhihu.com/?target=https%3A//www.bilibili.com/video/BV1i64y1u7Me/)\n\n![](pictures/20220908-153017.jpeg)\n## 目录\n\n- ### **令狐老师的算法小抄**\n\u003e[面试常考算法模板](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/blob/master/%E4%BB%A4%E7%8B%90%E8%80%81%E5%B8%88%E7%9A%84%E7%AE%97%E6%B3%95%E5%B0%8F%E6%8A%84/%E9%9D%A2%E8%AF%95%E5%B8%B8%E8%80%83%E7%AE%97%E6%B3%95%E6%A8%A1%E6%9D%BF%20Cheat%20Sheet%20V4.3.pdf)\n\n\n\u003e[北大学霸的算法刷题笔记](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/blob/master/%E5%8C%97%E5%A4%A7%E5%AD%A6%E9%9C%B8%E7%9A%84%E7%AE%97%E6%B3%95%E5%88%B7%E9%A2%98%E7%AC%94%E8%AE%B0.pdf)\n\n\n- ### **数据结构**\n\n\u003e[二叉树搜索](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E2%BC%86%E5%8F%89%E6%90%9C%E7%B4%A2%E6%A0%91)\n\n\u003e[二叉树分治](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E4%BA%8C%E5%8F%89%E6%A0%91%E5%88%86%E6%B2%BB)\n\n\u003e[哈希表](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E5%93%88%E5%B8%8C%E8%A1%A8)\n\n\u003e[堆](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E5%A0%86)\n\n\u003e[字典树](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E5%AD%97%E5%85%B8%E6%A0%91)\n\n\u003e[栈](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E6%A0%88)\n\n\u003e[链表](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E9%93%BE%E8%A1%A8)\n\n\n\u003e[线段树知识点总结](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E4%B8%8E%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E7%BA%BF%E6%AE%B5%E6%A0%91%E7%9F%A5%E8%AF%86%E7%82%B9%E6%80%BB%E7%BB%93.md)\n\n\n- ### **算法思维**\n\u003e[新手编程必刷50题](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/blob/master/%E7%BC%96%E7%A8%8B%E6%96%B0%E6%89%8B%E5%BF%85%E5%88%B750%E9%A2%98%20V1.0.docx)\n\n\u003e[二分法](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E4%BA%8C%E5%88%86%E6%B3%95)\n\n\u003e[位运算](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E4%BD%8D%E8%BF%90%E7%AE%97)\n\n\u003e[分治法](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E5%88%86%E6%B2%BB%E6%B3%95)\n\n\u003e[双指针](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E5%8F%8C%E6%8C%87%E9%92%88)\n\n\u003e[字典MAP](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E5%AD%97%E5%85%B8MAP)\n\n\u003e[并查集](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E5%B9%B6%E6%9F%A5%E9%9B%86)\n\n\u003e[排序算法](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E6%8E%92%E5%BA%8F%E7%AE%97%E6%B3%95)\n\n\u003e[贪心算法](https://github.com/ninechapter-algorithm/ninechapter-algorithm/tree/master/%E7%AE%97%E6%B3%95%E6%80%9D%E7%BB%B4%E9%A2%98/%E8%B4%AA%E5%BF%83%E7%AE%97%E6%B3%95)\n\n\n\n- ### **动态规划**\n\n\u003e[动态规划十问十答](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E4%B8%8E%E6%95%B0%E6%8D%AE%E7%BB%93%E6%9E%84/%E5%8A%A8%E6%80%81%E8%A7%84%E5%88%92%E5%8D%81%E9%97%AE%E5%8D%81%E7%AD%94.md)\n\n\n- ### **系统设计**\n\n\u003e[如何答好面试中的系统设计题](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%B3%BB%E7%BB%9F%E8%AE%BE%E8%AE%A1%20Syestem%20Design/%E5%A6%82%E4%BD%95%E7%AD%94%E5%A5%BD%E9%9D%A2%E8%AF%95%E4%B8%AD%E7%9A%84%E7%B3%BB%E7%BB%9F%E8%AE%BE%E8%AE%A1%E9%A2%98.md)\n\n- ### **图论**\n\u003e[宽度优先搜索](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/tree/master/%E5%9B%BE%E8%AE%BA/%E5%AE%BD%E5%BA%A6%E4%BC%98%E5%85%88%E6%90%9C%E7%B4%A2)\n\n\u003e[深度优先搜索](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/tree/master/%E5%9B%BE%E8%AE%BA/%E6%B7%B1%E5%BA%A6%E4%BC%98%E5%85%88%E6%90%9C%E7%B4%A2)\n\n- ### **FANNG面试高频题**\n）\n\u003e[算法面试必刷100题](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/blob/master/%E9%AB%98%E9%A2%91/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E5%BF%85%E5%88%B7100%E9%A2%98.xlsx)\n\n\u003e[数组题](https://github.com/ninechapter-algorithm/linghu-algorithm-templete/tree/master/%E9%AB%98%E9%A2%91/%E6%95%B0%E7%BB%84%E9%A2%98)\n\n\u003e[Google 面试题 | 原子计数](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E9%A2%98%E8%A7%A3/Google%20%E9%9D%A2%E8%AF%95%E9%A2%98%20%7C%20%E5%8E%9F%E5%AD%90%E8%AE%A1%E6%95%B0.md)\n\n\u003e[Google 面试题 | 3个非重复子数组最大和](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E9%A2%98%E8%A7%A3/Google%20%E9%9D%A2%E8%AF%95%E9%A2%98%20%7C%203%E4%B8%AA%E9%9D%9E%E9%87%8D%E5%A4%8D%E5%AD%90%E6%95%B0%E7%BB%84%E6%9C%80%E5%A4%A7%E5%92%8C.md)\n\n\u003e[Google 面试题 | 字典里面的最长单词](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E9%A2%98%E8%A7%A3/Google%20%E9%9D%A2%E8%AF%95%E9%A2%98%20%7C%20%E5%AD%97%E5%85%B8%E9%87%8C%E9%9D%A2%E7%9A%84%E6%9C%80%E9%95%BF%E5%8D%95%E8%AF%8D.md)\n\n\u003e[Google 面试题 | 找二叉树最底层最左边的节点](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E9%A2%98%E8%A7%A3/Google%20%E9%9D%A2%E8%AF%95%E9%A2%98%20%7C%20%E6%89%BE%E4%BA%8C%E5%8F%89%E6%A0%91%E6%9C%80%E5%BA%95%E5%B1%82%E6%9C%80%E5%B7%A6%E8%BE%B9%E7%9A%84%E8%8A%82%E7%82%B9.md)\n\n\u003e[Google 面试题 | 合法的IP的地址](https://github.com/ninechapter-algorithm/ninechapter-algorithm/blob/master/%E7%AE%97%E6%B3%95%E9%9D%A2%E8%AF%95%E9%A2%98%E8%A7%A3/Google%20%E9%9D%A2%E8%AF%95%E9%A2%98%20%7C%20%E5%90%88%E6%B3%95%E7%9A%84IP%E7%9A%84%E5%9C%B0%E5%9D%80.md)\n","funding_links":[],"categories":["Others"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fninechapter-algorithm%2Fleetcode-linghu-templete","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fninechapter-algorithm%2Fleetcode-linghu-templete","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fninechapter-algorithm%2Fleetcode-linghu-templete/lists"}