当前位置:网站首页>Summary of common skills
Summary of common skills
2022-07-26 08:17:00 【Misty rain】
2021/12/9
The two strings are trie On the tree LCA It's two substrings lcp
The two prefixes are SAM Of parent On the tree lca, Is the longest common suffix of these two prefixes (AHOI differences )
KMP The number of occurrences of each prefix on the mismatch tree of is equal to the number of points in its subtree plus one
ACAM Of fai The number of points in each subtree on the tree is the number of occurrences of this point in all strings
2021/12/10
If a function value f ( x ) f(x) f(x) be equal to x The function values of all factors add up , also f ( 1 ) f(1) f(1) yes 1, So this is Mobius function
The properties of the minimum spanning tree :
1: When the edge less than a certain weight is added , The connection of the whole picture is certain
2: In the minimum spanning tree , The number of edges of a weight in the tree is fixed
2021/12/13
CDQ The outermost layer of partition is best shaped like a ≤ b a\leq b a≤b instead of a < b a<b a<b
Otherwise, special judgment is required , And if the two elements are exactly the same, it may be less remembered. The contribution should be combined first
When calculating the slope, it is necessary to judge whether there will be x The same results in less than once
Slope optimization must be judged clearly , Dot x Are the coordinates orderly
When the decision is monotonous, divide and conquer
If it is layered , Or the calculation is more troublesome , Write with divide and conquer , Similar to the whole dichotomy
If you can O ( 1 ) O(1) O(1) perhaps O ( l o g n ) O(logn) O(logn) Calculated , Select two points + Monotonic stack
2021/12 26
DP When , If not enough, open another array
Sometimes the state can be expressed by difference , Reduce complexity
2021/12/28
Edge weights in graphs , You can turn an edge into a point by creating a new point on it
The point weight in the graph , You can split a point into input points and output points and convert them to edges
2021/1/5
2-sat If you are afraid of less conditions, you can consider all points
The optimization of line segment tree should be started 5 Times the space
边栏推荐
- Awk operation
- [endnote] detailed explanation of document template layout syntax
- Flex three column layout
- The most complete network: detailed explanation of six constraints of MySQL
- Differences and connections of previewkeydown, Keydown, keypress and Keyup in C WinForm
- Dev gridcontrol captures key events
- 苹果强硬新规:用第三方支付也要抽成,开发者亏大了!
- Excel file reading and writing (creation and parsing)
- 2022/7/17 exam summary
- Excel file parsing
猜你喜欢

File parsing (JSON parsing)

Understand microservices bit by bit

万字长文 | 深入理解 OpenFeign 的架构原理

Matplotlib learning notes

One click deployment lamp and LNMP architecture

JSP built-in object (implicit object) -- input / output object

Rack server expansion memory

Burp Suite-第六章 如何使用Burp Spider

Burp Suite - Chapter 1 burp suite installation and environment configuration

小蜜蜂吉他谱 高八度和低八度
随机推荐
美女裸聊一时爽,裸聊结束火葬场!
Burp Suite-第三章 如何使用Burp Suite代理
Burp Suite-第一章 Burp Suite 安装和环境配置
Burp suite Chapter 3 how to use burp suite agent
2022-07-08 group 5 Gu Xiangquan's learning notes day01
matplotlib学习笔记
Guitar staff link Jasmine
Let's talk about the three core issues of concurrent programming.
What are the differences between FileInputStream and bufferedinputstream?
2w字详解数据湖:概念、特征、架构与案例
Rewriting and overloading
Strtus2历史漏洞复现
2022/7/7 exam summary
Basic introduction of JDBC
Spotty music data client_ ID account
要不你给我说说什么是长轮询吧?
小组成员参加2022中国多媒体大会
我,35岁了。
The difference between equals() and = =
A little awesome, 130000 a month+