{"id":27139676,"url":"https://github.com/upupming/algorithm","last_synced_at":"2025-04-08T04:59:07.823Z","repository":{"id":42401751,"uuid":"217478998","full_name":"upupming/algorithm","owner":"upupming","description":"acwing, leetcode, kickstart, 算法模板, PAT 等等","archived":false,"fork":false,"pushed_at":"2024-02-26T05:17:37.000Z","size":2333,"stargazers_count":264,"open_issues_count":0,"forks_count":62,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-02-26T06:27:59.436Z","etag":null,"topics":["acwing","algorithm","competitive-programming","cpp","frontend","interview","javascript","kick-start","leetcode","pat","pseudocode","template","typescript"],"latest_commit_sha":null,"homepage":"https://upupming.site/tags/algorithm/","language":"C++","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/upupming.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,"governance":null}},"created_at":"2019-10-25T07:41:19.000Z","updated_at":"2024-02-19T12:39:12.000Z","dependencies_parsed_at":"2023-10-16T17:06:37.665Z","dependency_job_id":"a4332499-98bd-4f54-b562-f739eba9d201","html_url":"https://github.com/upupming/algorithm","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/upupming%2Falgorithm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/upupming%2Falgorithm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/upupming%2Falgorithm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/upupming%2Falgorithm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/upupming","download_url":"https://codeload.github.com/upupming/algorithm/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247779694,"owners_count":20994573,"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":["acwing","algorithm","competitive-programming","cpp","frontend","interview","javascript","kick-start","leetcode","pat","pseudocode","template","typescript"],"created_at":"2025-04-08T04:59:07.291Z","updated_at":"2025-04-08T04:59:07.817Z","avatar_url":"https://github.com/upupming.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# algorithm\n\n\u003e Forked from [liuchuo/PAT](https://github.com/liuchuo/PAT).\n\n主要存放训练刷题时的代码，有些有 README，有些源代码里面有注释可以看。\n\n- [AcWing](acwing)\n    - [算法基础课](acwing/算法基础课)\n    - [算法竞赛进阶指南](acwing/算法竞赛进阶指南)\n- **我的算法模板 [template.md](template.md)**\n    - TypeScript 算法模板 [template-typescript.md](template-typescript.md)\n    - [contest.js](https://github.com/harttle/contest.js) —— 用于 TS/JS 的算法模板库\n    - [algojs](https://github.com/upupming/algojs/)—— 我自己的 TS/JS 的算法模板\n- 我的对拍程序 [matcher.cpp](matcher.cpp)\n- Google KickStart [kick-start](kick-start)\n- LeetCode [leetcode](leetcode)\n    - [残酷刷题](leetcode/残酷刷题), [主页](http://cruelcoding.com/)\n        - 想加入残酷刷题群的朋友可以联系我\n        - [残酷刷题群2021年会](https://www.bilibili.com/video/BV1SL411V7Sd)\n        - [残酷刷题群2020年会总结](https://zhuanlan.zhihu.com/p/341323903)\n        - [群规链接](http://board.cruelcoding.com/rules.html)\n    - lcpredictor: https://lcpredictor.herokuapp.com/\n    - clist.by: https://clist.by/account/upupming/resource/leetcode.com/\n- [校招笔试 2022-online-assessments](2022-online-assessments/README.md)\n- 伪代码 [pseudoCode](pseudoCode)\n- 其他的都是之前刷 PAT 时候的题目\n\n## 关于算法复杂度\n\n在竞赛中，一般算机一秒能运行5 x 10^8次汁算，如果题目給出的时间限制カ1s,那么你选择的算法执行的计算次数最多应该在10^8量级オ有可能解决这个题目。一般 O(n)的算法能解决的数据范围在n \u003c 10^8。\n\n- O(n*logn)的算法能解决的数据范围在n \u003c= 10^6。\n- O(n*sqrt(n) )的算法能解决的数据范围在n \u003c 10^5。\n- O(n^2)的算法能解决的数据范围在n\u003c5000。\n- O(n^3)的算法能解决的数据范围在n \u003c300。\n- O(2^n)的算法能解决的数据范围在n \u003c 25。\n- O(n!)的算法能解决的数据范围在n \u003c 11。\n\n以上范围仅供参考，实际中还要考虑每种算法的常数。\n\n## 推荐一些优质的资源\n\n- [《算法竞赛进阶指南》打卡活动](https://www.acwing.com/activity/content/introduction/6/)\n- [《算法竞赛进阶指南》资源社区](https://github.com/lydrainbowcat/tedukuri)\n- [yxc的B站](https://space.bilibili.com/7836741/)\n- [残酷刷题群排行榜](https://wisdompeak.github.io/lc-score-board/)、[残酷刷题群题目清单](https://docs.google.com/spreadsheets/d/1kBGyRsSdbGDu7DzjQcC-UkZjZERdrP8-_QyVGXHSrB8/edit)、[wisdompeak的B站](https://space.bilibili.com/695330558/)\n    - [群友YoungForest的博客](https://youngforest.github.io/)\n    - [灵神的模板库 codeforces-go](https://github.com/EndlessCheng/codeforces-go)\n    - [群友Bill0412的博客](https://kickstart.best/)\n    - [OTTFF的B站](https://space.bilibili.com/97228279/)\n    - [zerotrac的B站](https://space.bilibili.com/3203291/)\n    - [LeetCode 题目难度分查询](https://zerotrac.github.io/leetcode_problem_rating/)\n    - https://github.com/lzl124631x/LeetCode\n- [lucifer1004的CP笔记](https://cp-wiki.vercel.app/)\n    - [lucifer1004的B站](https://space.bilibili.com/2403384/)\n- [tiger_2005的B站](https://space.bilibili.com/350620554/)\n- [Errichto 的 YouTube](https://www.youtube.com/channel/UCBr_Fu6q9iHYQCh13jmpbrg)\n- [William Lin 的 YouTube](https://www.youtube.com/channel/UCKuDLsO0Wwef53qdHPjbU2Q)\n- [lee215 的 YouTube](https://www.youtube.com/channel/UCUBt1TDQTl1atYsscVoUzoQ)、[lee215 的公众号](https://mp.weixin.qq.com/s/5tcPvmaga1ia31lYqYbNYA)\n- [OI WiKi](https://github.com/OI-wiki/OI-wiki)\n- [ACM 模板库](https://github.com/F0RE1GNERS/template)\n- [Tushar Roy 的 YouTube](https://www.youtube.com/user/tusharroy2525)、[Tushar Roy 的代码库](https://github.com/mission-peace/interview)\n- [栗子的 KickStart 题解](https://github.com/lzy960601/Google_Coding_Competitions)\n- [Range Minimum Query - TopCoder](https://www.topcoder.com/community/competitive-programming/tutorials/range-minimum-query-and-lowest-common-ancestor/)\n- [Pecco 的算法学习笔记](https://www.zhihu.com/column/c_1182444932760125440)\n\n## Stargazers over time\n\n[![Stargazers over time](https://starchart.cc/upupming/algorithm.svg)](https://starchart.cc/upupming/algorithm)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fupupming%2Falgorithm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fupupming%2Falgorithm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fupupming%2Falgorithm/lists"}