GithubHelp home page GithubHelp logo

don2025 / codeforces-go Goto Github PK

View Code? Open in Web Editor NEW

This project forked from endlesscheng/codeforces-go

0.0 0.0 0.0 117.67 MB

Golang 算法竞赛模板库 | Solutions to Codeforces by Go 💭💡🎈

License: MIT License

JavaScript 0.15% Go 99.85%

codeforces-go's Introduction

codeforces-go 💭💡🎈

算法 Algorithm

由于算法知识点繁杂,将自己学习到的算法、做过的题目分类整理好是有必要的。

一个算法模板应当涵盖以下几点:

  • 对该算法的基本介绍(核心**、复杂度等)
  • 参考链接或书籍章节(讲的比较好的资料)
  • 模板代码(可以包含一些注释、使用说明)
  • 模板补充内容(常见题型中的额外代码、建模技巧等)
  • 相关题目链接(模板题、经典题、思维转换题等)

算法目录

不了解 Go?快速入门教程

如何选择题目 How to Choose Problems

Rating < 2100

这一阶段主要目标是提高对问题的观察能力。做构造题可以针对性地训练这一点。

选择难度在自己 rating 到 rating+200 范围内的构造题 (tag: constructive algorithms),按照过题人数降序做题,比如 [1700,1900] 区间的就是下面这个链接:

https://codeforces.com/problemset?order=BY_SOLVED_DESC&tags=constructive+algorithms%2C1700-1900

通过大量的构造题训练,提高观察能力,快速找到切题入口。具体见我在知乎上的这篇 回答

Rating >= 2100

这一阶段要想上分,应以 DP 为主,图论和数据结构为辅。难度范围选择同上,可以根据自己在该项的能力上下调整。

我的 Codeforces 账号:

0x3F

测试及对拍 Testing

编写一个 run(io.Reader, io.Writer) 函数来处理输入输出。这样写的理由是:

  • main 中调用 run(os.Stdin, os.Stdout) 来执行代码;
  • 测试时,将测试数据转换成 strings.Reader 当作输入,并用一个 strings.Builder 来接收输出,将这二者传入 run 中,然后就能比较输出与答案了;
  • 对拍时需要实现一个暴力算法 runAC,参数和 run 一样。通过 随机数据生成器 来生成数据,分别传入 runACrun,通过比对各自的输出,来检查 run 中的问题。

具体可以见 Codeforces 代码仓库 main,所有非交互题的代码及其对应测试全部按照上述框架实现。

例如:1439C_test.go

交互题的写法要复杂一些,需要把涉及输入输出的地方抽象成接口,详见 interactive_problem

学习资料及题目 Resources

注:由于入门经典上选了很多区域赛的题,一部分题目可以在 GYM 上找到,这样可以就可以用 Go 编程提交了。

算法竞赛入门经典(第二版)

算法竞赛入门经典训练指南

算法竞赛入门经典训练指南(升级版)

算法竞赛进阶指南

算法竞赛入门到进阶

OI Public Library(含国家队论文)

算法竞赛 (ICPC, OI, etc) 论文,课件,文档,笔记等

算法竞赛课件分享 by hzwer

算法第四版 Java 源码

数据结构和算法动态可视化

OI Wiki

CP-Algorithms

洛谷日报

All the good tutorials found for Competitive Programming

Codeforces Problem Topics

GeeksforGeeks 上的算法合集

Pepcy 模板

F0RE1GNERS 模板

【模板整合计划】目录

算法学习笔记(目录)

洛谷模板题(建议按难度筛选)

能力全面提升综合题单

Luogu Problem List

洛谷原试炼场

Links of ICPC/CCPC Contests from China

AtCoder 版《挑战程序设计竞赛》

AtCoder 版!蟻本 (初級編)

AtCoder 版!蟻本 (中級編)

AtCoder 版!蟻本 (上級編)

AtCoder 版!蟻本 (発展的トピック編)

待整理

【杂文】记一些有用的神奇网站

偶然在 GitHub 上发现的超长列表

算法竞赛训练中较难的部分

算法竞赛中可能不太会遇到的论文题

[杂谈]OI/ACM中冷门算法

https://blog.csdn.net/calabash_boy/article/details/79973483

https://github.com/zimpha/algorithmic-library

https://www.luogu.com.cn/blog/command-block/blog-suo-yin-zhi-ding-post

https://wcysai.github.io/

https://www.luogu.com.cn/blog/Troverld/index

其他 Others

My GoLand Live Templates and Postfix Completion settings

Useful Tools

GeoGebra 经典

Draw Geometry

Draw Graph

OEIS

Wolfram|Alpha

UpSolve.me

Codeforces Upsolving Helper

Contests Filter

Codeforced

Codeforces Visualizer

Codeforces Solve Tracker

Another Codeforces Solve Tracker

Rating and Difficulties

Open Codeforces Rating System

How to Interpret Contest Ratings

Codeforces: Problem Difficulties

Elo rating system

Stay Healthy

Exercises!

codeforces-go's People

Contributors

endlesscheng avatar j178 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.