ACM training plan recommendations (transfer)

Foreword :

The teacher asked us to organize a training plan for the next class of junior students. After sorting it out, it took a lot of writing and ink, so I put it on the blog garden for your reference.

If you are a rookie, don't spray it. If there is anything inappropriate or supplementary, please point out.

This proposal is divided into three stages, freshman, sophomore and junior. The senior year has not been sorted out yet. On the one hand, the senior year has to face the problem of testing and finding a job, and few people insist on continuing ACM. On the other hand, I am not a senior yet...

The following is an analysis of the recommended learning content and specific training plan in these three stages based on personal experience.

 

Text :

Freshman (first stage) :

  Freshman year is the most abundant period of time, and it is also the stage with the highest plasticity. In your freshman year, you have a lot of free time to allocate by yourself. It is recommended that you lay a solid foundation in c/c++, or any language, and try to be "semi-proficient" during this time. Because in a language like C++, it is impossible to achieve mastery in a few years. The "semi-proficient" I am talking about here is actually based on the complete understanding of the textbook, and then expand some content outside the classroom to deepen the understanding of the language itself.

  Why do I stress the importance of language here? On the one hand, it is for the needs of acm in the future. The language is smooth, which can ensure that you can implement most of the algorithms without obstacles. In the competition, time is very important. On the other hand, it is also an ability that you must learn as a computer student. Language is the sword in your hand. How far you can go in the future depends on how sharp the sword is.

  On the other hand, it is recommended to lay a solid foundation in mathematics. As a former senior, he suffers from bad mathematics. The later acm is, the more mathematical knowledge is actually used. Like some questions, the naked thing is to ask for points, and there are some questions that embed the expectations into the DP questions... In fact, these are all explicit questions, and there is an implicit thing, which is most helpful to acm. , that is mathematical thinking. The difference between mathematical thinking and non-mathematical thinking is the difference between N ideas and N*N ideas for a question. This becomes more and more obvious in the later stage. The idea is very important. When facing a problem in the competition, the team must first have a variety of ideas for analysis, and then everyone will discuss which idea is the most feasible, and then the person who is best at this idea will realize it algorithm. If there are very few ideas generated when analyzing a question, it will undoubtedly reduce the AC hit rate of this question.

  Having said so much, I actually want to emphasize two points for the freshmen, language and mathematics .

  For specific implementation strategies, in mathematics, take a good class and understand the textbook.

  For language, suggestions: textbook + brushing questions | If you don't know, ask the teacher.

  At this stage, in addition to the OJs of our school, you can also go to major OJs to write the questions. There are many water questions on poj, and the quality is high. Here is a list of poj water questions (transfer).


 

poj1000:A+B problem

poj1002: The keys on the phone correspond to numbers. Now give n calls and ask for sorting. same category

poj1003: Find the smallest n such that 1+1/2+1/3+...+1/n is greater than a given real number

poj1004: Find the average of a bunch of real numbers

poj1005: Start from the coordinate (0,0), erode 50m^2 per year in the shape of a semicircle, ask how long it takes from the start of (0,0) to the end of (x,y)

poj1006: Three periods are constant. Now give three cycles when the peak occurs, ask when the next peak will occur

poj1007: find string sorting

poj1008: A calendar that counts the number of days

poj1012: Joseph problem

poj1013: Give the result of weighing a coin 3 times and ask which is the counterfeit coin and the counterfeit coin is lighter or heavier than the real coin

poj1016: A number string changes like this: its successor is: it contains several 1s, contains several 2s... Ask the loop situation

poj1017: 1×1, 2×2, 3×3, 4×4, 5×5, 6×6 products are put into 6×6×h boxes. Find the minimum value of h.

poj1028: Simulate web browsing

poj1031: Find if a point is inside the convex hull

poj1032: Divide n into the sum of several different numbers and find the maximum product

[2+3+...If there is more, add 1 from the largest number]

POJ1045: Mathematical formulas

poj1046: Give 16 background colors, and then give several colors to ask which is the smallest distance from the front?

poj1051: A string with one substitution for each letter. Now replace that replacement and go back to find the original string.

poj1056: Given several strings, ask if one is a prefix of the other?

[Actually, it can be done with trie, but violence can be passed]

poj1061: Given the coordinates of two frogs (a meridian line), the distance of each frog bar once, how many times can you hit it by jumping?

poj1065: Process n sticks, each with two arguments. If one of the previous processing is not larger than it, the conversion time can be omitted, otherwise it takes 1 time. Ask the minimum conversion time?

poj1083: There are 400 rooms in total, 200 in the south and 200 in the north. It takes 10 minutes to move things from one room to another. During this period, other people cannot pass this road. A room can be moved in or out at most once.

[Count how many times each road passes to find max]

poj1118: Find the number of points in the line with the most points for several points

poj1146: find a lexicographical order after a string

[next_permutation function]

poj1183: arctan(1/a)=arctan(1/b)+arctan(1/c), give a, find the minimum solution for b+c

【Mathematical derivation】

poj1207: Each number performs the following operations: if it is an even number/2, if it is an odd number*3+1. Ask the number of operations of the number that can operate the most operations in an interval

【You can do it directly】

poj1218: Find the number of squares between 1-n

poj1256: Find the full permutation of a string

[next_permutation function]

poj1298: letter substitution problem

poj1517: Find the value of i=0-9 e=∑0<=i<=n1/i!

poj1657: Find the shortest distance between king, queen, rook, and elephant for the starting and ending points on the chessboard

poj1833: find the next lexicographical order

[next_permutation function]

poj1835: Simulate an astronaut movement. (Three-dimensional, turn left, turn right, turn up, turn down, turn forward and then turn)

poj1936: Give two s and t two strings. Ask if t can be the same as s after deleting some characters

poj2027: Compare the size of two numbers

poj2159: Two passwords. Ask if the former is the original code of the latter.

[The same number of letters are the same]

poj2262: Goldbach's conjecture for even numbers within 1000000

poj2606: Find the number of points in the line with the most points for several points

poj2656: There are n days, if one day's class time + extra-curricular time > 8, I'm not happy. Find the earliest unhappy time of the day.

poj2663: 2×1 domino cards to cover the number of 3×n rectangles

poj2739: Find the sum of how many consecutive primes a number can be represented as.

poj2780: Find the number of points in the line with the most points for several points

poj3006: Given a sequence (prime tolerance), find the nth prime number in this sequence

poj3087: Keep shuffling the cards, how many times can you reach the target state?

poj3094: re-output the input

poj3175: Given a string, find the first n significant digits of the fractional part of the square root of that integer, that is the string?

poj3299: There are three variables and derivation formulas, any two to find the third.

poj3589: Number guessing game to determine how many A and B are there in two numbers

poj3618: How many scenic spots can a person pass through each time he goes to the closest scenic spot (with positive and negative) to the origin?

poj3619: Everyone reads at a speed and stops after a certain amount of time. How long does it take each person to read how many pages

poj3620: Find the largest connected block

poj3627: ask the least people to make their height more than a number

poj3663: Give n numbers. ask how many pairs of numbers and <=s

poj3664: Two rounds of voting, the top m in the first round enter the second round; the highest vote in the second round is the champion

poj3665: Take the largest number each time, and then score it to the remaining n-1 numbers. If it cannot be divided equally, add it from the number 1. Number order

poj3671: n 1s and 2s, how many numbers can be modified to make the whole sequence orderly? (1 in front and 2 in back)

poj3672: It takes time to go uphill and time to go downhill. Now give the route you went to find the time required for the route back

poj3673: Alternative multiplication, the sum of the products of two numbers on each bit

poj3749: Decrypt a string. Each string is the original letter pushed back 5 letters


 

 

Sophomore Year (Second Stage) :

  Sophomore year is a very important period, we must grasp it well, especially grasp the direction of learning, and study with purpose.

  So at the beginning of the semester, make a study plan for yourself first. There are two semesters in the sophomore year. I analyze my strengths and weaknesses, what I am good at and what I am not good at, and what I am interested in, and then comprehensively clarify what I should do this year and what degree I should achieve.

  Here are personal suggestions, the first semester, data structure, the second semester, choose a few directions to specialize in .

  The data structure suggested in the first semester is not only the foundation of many directions in acm, but also an important foundation for learning computers, so it is recommended that students lay a solid foundation for data structure. In terms of time, I just give a reference, you can arrange your own time according to your own interests and courses. You can focus on it during the holidays, or you can wait for the teacher to study while he is in class.

  Regarding the recommended specialization in the second semester, here is a key point to explain, acm covers a wide range of fields, our time is limited, you can't be proficient in all directions, and acm is a team game, so you You and your teammates can each be responsible for specializing in several directions, so that there will be no situation where no one has any ideas for a question during the game. In addition, it is recommended that everyone specialize in a certain direction of intersection. Otherwise, no one will discuss with you during the competition, which will reduce the correct rate of this question. In fact, in the later stage, our team (just our team) did not rely on this model, but changed to two people discussing ideas + one person typing the code, which is arranged according to the characteristics of each team. Of course, I think it is still necessary to divide the direction, because this reasonably distributes the energy of everyone in the team, and ensures that there are no loopholes in the team's knowledge in a short period of time. After all, one bite will not make you fat.

 

The following are the major directions of our division, for your reference (the ranking is in no particular order).

1. Number Theory

2. Graph theory

3. Dynamic programming

4. Computational geometry

5. Search

6. Game

7. Combinatorics

8. Data structure

9. Simulation

 

Personal impressions and recommended topics of these nine directions (partially reproduced):

For the collection of questions in each direction, please refer to the link: http://blog.csdn.net/liuqiyao_01/article/details/9079611

1. Number Theory

There are probably prime number test (sieve method), extended Euclidean algorithm, congruence modular operation, Gaussian elimination, Chinese remainder theorem, Mobius inversion and so on.

I'm not good at this (mathematics sucks, but fortunately there are two math masters in the later team), so I don't comment.

Recommended topics:

Congruence modular operation: poj2635, poj3292, poj1845, poj2115

Prime number test and sieve method: poj2191, poj1811

Gaussian elimination: poj1681, poj1222

Extended Euclidean Algorithm: poj2891, poj1061

Chinese remainder theorem: poj1006, zoj3538

Mobius inversion: poj2154

2. Graph theory

Shortest path, minimum spanning tree, topological sort, bipartite graph, maximum clique, maximum flow, strongly connected component, nearest common ancestor, next smallest spanning tree, Euler circuit, Hamiltonian circuit, etc.

The theory of graph theory is deep, the implementation is troublesome, and it is not easy to chew.

Recommended topics:

Minimum cost maximum flow (poj2516, poj2516, poj2195)

Biconnected Components (poj2942)

Strongly connected branches and their indentations. (poj2186)

Cut edges and cut points of graphs (poj3352)

Minimum cut model, network flow reduction (poj3308, )

3. Dynamic programming

Knapsack problem, tree DP, digital DP, etc.

Dynamic programming gives me the feeling that a question in the game involves DP, which is basically a problem...

No kidding, dynamic programming is difficult, it takes time to accumulate (do more questions), and what needs to be exercised is the idea of ​​​​using dynamic regression to solve problems, which is not urgent.

Recommended topics:

Backpack problem: hdu2602, poj3624, hdu2546, hdu2955, poj2184, hdu2639

Tree DP: poj1155, hdu1011, poj1947, hdu1561, hdu4003, poj2486

Probability DP: zoj3383, zoj3460, hdu4405, hdu4336

Digital DP: hdu2089, hdu3555, hdu3652, poj3252

4. Computational geometry

Dot product and cross product, line segment intersection, polygon area, convex hull, half plane, tangent of circle and point, intersection of circle and line, intersection of circle and circle, union and intersection of circle and polygon, 3D convex hull, 3D point and straight lines, etc.

Computational geometry is complicated, difficult to implement, and the problem of accuracy is even more tangled (the direction I am responsible for, I have tears when I study, I haven't passed the two provincial competitions...cry).

Recommended topics:

Dot product and cross product: poj2318, poj2398

Line segment intersection: poj3304, poj1269, poj2653, poj1066, poj1039

Convex hull: poj1113, poj3348, poj1318, poj1696, hdu1392, poj2187, hdu1348

Half-plane intersection: poj3335, poj3130, poj1474, poj1278

Manhattan distance: hdu4666, poj2926

5. Search

dfs, bfs, A*, IDA*, two-way wide search, etc.

The early search is relatively easy to get started, and the later search problems are really difficult.

There seems to be no separate search questions for provincial competitions in recent years.

Recommended topics:

dfs:poj1724、hrbustoj1179、hdu1728、hdu1045、hdu1312、sdut2152、hdu1426、poj2386、hdu2553、hdu1022、hdu1241、hdu1016、hdu1010、hdu1175

bfs:poj3984、poj3278、hdu1242、hdu1240、hdu1195、hdu2717、hdu1253、hdu1026、hdu1180、hdu2612

6. Game

Bash game, Wyzhov game, Fibonacci game, Nim game, fair combination game, etc.

I am not familiar with the game, it seems that I am looking for a winning state, of course I can also find the rules...

The game code is generally very short, as long as the formula (or law) is analyzed, it is not difficult to implement.

Recommended topics:

poj1067、poj1740、poj2234、poj1082、poj2348、poj2413、poj2419

7. Combinatorics

Inclusion and exclusion principle, drawer principle, permutation group and Polya theorem, generating function, etc.

I remember that there were many combinatorial math problems in the fifth provincial competition...

Recommended topics:

Permutation groups: poj2369, poj1026, poj1721, poj3270, poj1879

Polya定理:hdu1812、hdu1817、hdu2481、hdu1286

Inclusion and exclusion principle: hdu2204, hdu3208, hdu1796, hdu2841, hdu1695

8. Data structure

String processing, stacks and queues, trees, hashes, binary search, union search, segment trees, 2D segment trees, Huffman trees, suffix arrays, and more.

The content of data structure is relatively complex, and it involves basic knowledge. Many of the ideas can be used in other topics, and must be learned well.

Here it is used as a direction for some advanced data structures in the later stage, such as dictionary trees, partition trees, line segment trees, AC automata, and so on.

Recommended topics:

Find (binary, hash): poj3349, poj1002, hdu2141, hdu1025

String (AC automaton, KMP): hdu3695, hdu2203, sdut2411, poj2406, hdu1358, hdu3336

And check the set: poj2236, poj2524, poj1182, poj1611, hdu1232

Dictionary tree: poj2503, poj2001, hdu1247, hdu1075, hdu1251

Tree array: hdu1556, poj1195, poj3321, hdu1541/poj2352

Segment tree: poj2155, poj1195, poj3468, poj3264, hdu1556, hdu1698, hdu1754, hdu1166

Divide the tree: poj2104, sdut2610

9. Simulation

There is no example of simulation, it only appears as a question type here, and there is no fixed question type.

Simulation is mainly difficult to achieve, and ideas are often not difficult. As long as you are patient, pay attention to details, and think carefully, you will be fine.

Recommended topics:

hdu1030、hdu1033、hdu1035、hdu1057、hdu1063、hdu1002、hdu1004、hdu1013、hdu1015、hdu1017、hdu1020、hdu1022、hdu1029、hdu1031、hdu1033、hdu1034、hdu1035、hdu1036、hdu1037、hdu1039、hdu1042、hdu1047、hdu1048、hdu1049、hdu1050、hdu1057、hdu1062

 

Add 10 at the end.

10 、 STL

STL, Standard Template Library, Standard Template Library.

Need to know, the basic set, map, vector, queue, algorithm should be used.

Many problems need to be solved with stl, or even naked inspection of stl.

The advantage of Stl is convenience, and because it dynamically opens up memory, it can solve some problems that cannot be opened up in space.

For example, the hash space is too large and cannot be opened up at once. You can use set to solve it.

 

Junior year (third stage) :

  There are only two words for the junior year: strengthen .

  Don't underestimate this period, this is an important sublimation period that can create miracles. After the basic learning and direction extension in the first two stages, you already have the algorithm foundation, and have a certain insight to understand the algorithm knowledge in several directions. At this time, you can sink your heart to consolidate the knowledge you have learned, and slowly learn knowledge in other fields. This process is very slow and difficult, and there is little feedback that can make you feel a sense of accomplishment, so you will feel tired, feel hard, and even wonder if what you have learned is useless, and you will be tempted by the outside world during this period. Postgraduate entrance exams, doing projects... These will distract you, but I want to say, don't give up, this is your bottleneck period, and it is also a test of your ACM road. After passing it, you may gain unimaginable benefits. s return.

  There are two ways of strengthening here: one is to learn new knowledge by reading books and doing problems as mentioned earlier, and the other is to play games .

  Now that it is in the late stage, you have to learn to play regularly, play by yourself, and play with your teammates. On the one hand, you can exercise teamwork, and on the other hand, you can find your own loopholes well. Playing games at the same time is also a good way to stay in shape, lazy? exhausted? out of status? Pulled into the arena and worked tensely for a few hours, then I woke up. I remember when we were training on May 1st, there was a training game a day, and we went to the laboratory sleepy in the morning, and before we stretched out, we vigorously threw ourselves into the ranks of questions, reading questions, analyzing, discussing, typing code, the more I became more and more sober, and when the game was over, I suddenly realized that it was already afternoon...

 

There are also many ways to play games. You can find them yourself, or you can listen to my recommendations. Here are some examples:

1. Regular competition website

Bestcoder: For the games we often play, the quality of the questions needs to be studied, but it is still good for weekly practice.

Codeforces: The quality of the questions is high, and your score rating is also a highly credible measure of future job hunting.

Topcoder: I haven't played, I heard it's difficult.

2. Irregular competitions

You can follow Hangdian or some other oj's Recent Contests, and you can view some of the recent competitions held by other oj.

3、Virtual Judge

Virtual Judge can grab the questions of major oj and make it into a competition. If there is no competition in the near future, and you feel lonely and unbearable, you can use it to make a question for yourself.

Virtual Judge website: http://acm.hust.edu.cn/vjudge/toIndex.action

Register an account to DIY the competition.

 

In addition, some recommended books are given , you can refer to these books in the process of training or learning:

Liu Rujia series:

"Classic Introduction to Algorithm Competition" Liu Rujia (Xiao Bai)

This book is not thick, the topic is very flexible, and it is very good for getting started.

"Introduction to Algorithm Competition Classics (2nd Edition)" Liu Rujia (Purple Book)

Xiaobai's second edition, I didn't read the book, I don't know what's more, but it's thicker...

"Introduction to Algorithm Competition Classics - Training Guide" Liu Rujia (Dabai)

Dabai read a part, the language is easy to understand, and computational geometry is based on it.

"Algorithm Art and Informatics Competition" Liu Rujia (Black Book)

It's hard, I don't recommend watching it before junior year.

Many of Liu Rujia's book exercises are on UVA. The domestic access is very slow, and it seems to be blocked. You can use FQ to write the questions...

 

"discrete mathematics"

"Combinatorial Mathematics"

"data structure"

reference book

 

"Challenge Programming Contest"

It is said that this book is good, and I recommend it.

"Introduction to Algorithms"

This book is placed here for worship...

After you finish the exercises, you are a god.

 

Postscript :

  Note that the three stages are all very important, please do not waste any period, as the saying goes, "when to do things", do things A at this stage, and there are things B to do in the next stage, so please cherish the time, don't be half-hearted, don't Give up easily.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325141281&siteId=291194637