训练指南 第二章相关题目
在别人博客找的 帮上大忙了
#《算法竞赛入门经典——训练指南》第二章相关内容
由于动态规划的高阶比较难,所以伴随这数论一起刷
红色为做了黄色不懂的 希望各位大牛能帮帮小弟
P112.例题4,LA3516的图画错了,请参考原题:https://icpcarchive.ecs.baylor.edu/external/35/3516.html
[第二次印刷改正]p180. 表2-8 第一行信息有误,应为:
例题14 |
UVa11021 |
Tribbles |
离散概率;递推 |
以下是《算法竞赛入门经典——训练指南》第二章中的例题和习题列表。多数题目在书中已经给出了题目翻译,这里主要是为了让大家能方便的找到题解链接、数据下载等其他信息。
如果大家写了或者找到了下面题目(尤其是习题)的解题报告,欢迎留言推荐,我会做个链接 :)
或者有些题解网上找不到但你特别想知道怎么做,也可以留言,我们会努力在业余时间里选一些request很多的题目写点题解或者提示
UVa网站专门为本书设立的分类题库配合,方便读者提交:
http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=442
注意,下面注有“extra”的习题并没有在书中出现,但在上面的特别题库中有,属于附加习题。
基础练习 (Basic Problems)
GCD LCM |
|
Benefit |
|
How do you add? |
|
Again Prime? No time. |
|
LCM Cardinality |
|
The Super Powers |
|
Add Again |
|
Teams |
|
Palindrome Numbers |
|
Integer Game |
|
Minimum Sum LCM |
|
Square Numbers |
|
Maximum |
|
Crazy tea party |
例题1 |
Chess Queen |
基本计数原理 |
|
例题2 |
Triangle Counting |
基本计数原理 |
|
例题3 |
Cheerleaders |
容斥原理 |
|
例题4 |
Exploring Pyramids |
递推 |
|
例题5 |
Investigating Div-Sum Property |
整数区间分解;递推 |
|
例题6 |
Glenbow Museum |
递推;状态精简 |
|
例题7 |
Series-Parallel Networks |
综合应用 |
How Many 0's? |
|
Supermean |
|
Neon Sign |
|
Pinary |
|
Bits |
|
(extra)UVa10079 |
Pizza Cutting |
(extra)UVa10081 |
Tight Words |
(extra)UVa10157 |
Expressions |
(extra)UVa10312 |
Expression Bracketing |
(extra)UVa10497 |
Sweet Child Makes Trouble |
Highways |
|
Counting Triangles |
|
Strange Tax Calculation |
|
Magnetic Train Tracks |
|
Counting Heaps |
|
Arrange the Numbers |
|
Metal |
|
Bishops |
|
(extra)UVa10128 |
Queue |
(extra)UVa10458 |
Cricket Ranking |
(extra)UVa10623 |
Thinking Backward |
(extra)UVa10712 |
Counting the Numbers |
(extra)UVa11290 |
Gangs |
(extra)UVa11421 |
Arranging Cards |
(extra)UVa11885 |
Number of Battlefields |
(extra)UVa12034 |
Race |
(extra)UVa12508 |
Triangles in the Grid |
Counting Quadrilaterals |
|
Persephone |
|
Permutation Counting |
|
Delta Wave |
|
Math teacher's homework |
|
Binary Integer |
|
(extra)UVa10743 |
Blocks on Blocks |
(extra)UVa11379 |
Chichi's Home Work |
(extra)UVa11625 |
Nice Prefixes |
例题 (Examples)
例题8 |
Always an Integer |
多项式;差分;整除性 |
|
例题9 |
GCD |
gcd、phi函数 |
|
例题10 |
Code Feat |
中国剩余定理 |
|
例题11 |
Emoogle Grid |
离散对数 |
入门习题 (Exercises:Beginner)
Play with Floor and Ceil |
|
Just Another Problem |
|
Alternate Task |
|
Huge Mods |
|
Polynomial GCD |
|
Gauss Prime |
|
(extra)UVa10061 |
How many zero's and how many digits? |
(extra)UVa10090 |
Marbles |
(extra)UVa10110 |
Light, more light |
(extra)UVa10127 |
Ones |
(extra)UVa10140 |
Prime Distance |
(extra)UVa10368 |
Euclid's Game |
(extra)UVa10515 |
Powers Et Al. |
(extra)UVa10539 |
Almost Prime Numbers |
(extra)UVa10560 |
Minimum Weight |
(extra)UVa10622 |
Perfect P-th Powers |
(extra)UVa10710 |
Chinese Shuffle |
(extra)UVa11105 |
Semi-prime H-numbers |
中级习题 (Exercises:Intermediate)
Lattice Point or Not |
|
Discrete Square Roots |
|
Cryptography Reloaded |
|
GCD Guessing Game |
|
Make a Crystal |
|
Payment System |
|
The Bells are Ringing |
|
Prime k-tuple |
|
Vivian's Problem |
|
Different Digits |
|
Joseph's Problem |
|
YAPTCHA |
|
(extra)UVa10162 |
Last Digit |
(extra)UVa10236 |
The Fibonacci Primes |
(extra)UVa10413 |
Crazy Savages |
(extra)UVa10548 |
Find the Right Changes |
(extra)UVa10555 |
Dead Fraction |
(extra)UVa10620 |
A Flea on a Chessboard |
(extra)UVa10627 |
Infinite Race |
(extra)UVa10837 |
A Research Problem |
(extra)UVa11237 |
Halloween treats |
(extra)UVa11440 |
Help Tomisu |
(extra)UVa11657 |
Rational Billard |
提高习题 (Exercises:Advanced)
Simple Encryption |
|
Ji-Tu Problem |
|
Business Cards |
例题 (Examples)
例题12 |
Playing With Stones |
找规律;SG定理 |
|
例题13 |
Treblecross |
SG定理;输出方案 |
入门习题 (Exercises:Beginner)
Box Game |
|
ENimEN |
|
(extra)UVa11927 |
Games Are Important |
中级习题 (Exercises:Intermediate)
Addition-Subtraction Game |
|
A Funny Stone Game |
|
(extra)UVa11249 |
Game |
提高习题(Exercises:Advanced)
Alice and Bob |
|
(extra)UVa11758 |
Left Right |
(extra)UVa12033 |
Game of CS |
(extra)UVa12370 |
Game of Connect |
例题 (Examples)
例题14 |
Tribbles |
离散概率;递推 |
|
例题15 |
Joining with Friend |
连续概率;几何 |
|
例题16 |
Expect the Expected |
数学期望 |
|
例题17 |
Race To 1 |
马尔科夫过程;数学期望 |
Crossing Rivers |
|
Probability|Given |
|
Cows and Cars |
|
So you want to be a 2n-aire? |
|
(extra)UVa10288 |
Coupons |
(extra)UVa11291 |
Smeech |
(extra)UVa11346 |
Probability |
中级习题 (Exercises:Intermediate)
Garbage Remembering Exam |
|
Lights inside a 3d Grid |
|
(extra)UVa10417 |
Gift Exchanging |
(extra)UVa10529 |
Dumb Bones |
(extra)UVa11176 |
Winning Streak |
(extra)UVa11971 |
Polygon |
Activation |
|
Game |
|
Parallel Expectations |
|
The Great Game |
|
(extra)UVa11429 |
Randomness |
例题18 |
Arif in Dhaka (First Love part 2) |
等价类计数 |
|
例题19 |
Leonardo's Notebook |
置换分解;递推 |
|
例题20 |
Find the Permutations |
置换分解;置换乘法 |
|
例题21 |
Pixel Shuffle |
置换分解;置换乘法 |
入门习题(Exercises:Beginner)
Cubes |
|
Doom's Day |
|
The Colored Cubes |
中级习题 (Exercises:Intermediate)
Andy's Shoes |
|
Necklace |
|
Silly Sort |
提高习题(Exercises:Advanced)
Sultan's Chandelier |
|
Alphabet Soup |
|
(extra)UVa11924 |
Unlock the Winning Pot |
矩阵与线性方程组(Matrix & System ofLinear Equations)
例题(Examples)
例题22 |
Recurrences |
线性递推关系。Q矩阵 |
|
例题23 |
Cellular Automaton |
循环矩阵的乘法 |
|
例题24 |
Back to Kernighan-Ritchie |
马尔科夫过程;实数域的线性方程组(有特殊情况) |
|
例题25 |
Square |
XOR方程组 |
入门习题(Exercises:Beginner)
Contemplation |
|
Power of Matrix |
中级习题 (Exercises:Intermediate)
Rational Resistors |
|
The Teacher's Side of Math |
提高习题(Exercises:Advanced)
Kid's Problem |
例题(Examples)
例题26 |
Solve It |
非线性方程求根 |
|
例题27 |
Error Curves |
凸函数求极值 |
|
例题28 |
Bridge |
数值积分 |
入门习题(Exercises:Beginner)
Expanding Rods |
|
Duathlon |
|
(extra)UVa10693 |
Traffic Volume |
中级习题 (Exercises:Intermediate)
Volume |
|
Tough Water Level |
|
Timer |
|
(extra)UVa11102 |
Moonshine |
提高习题(Exercises:Advanced)
Big Decimal Calculator
|