I. Concepts and CLASSIFICATIONS
Second, the storage structure of graphs
1. Adjacency Matrix
Vertex:
Arc:
Side:
An expression statement:
2. adjacency table
Inverse adjacency table:
3. Cross linked list
4. Adjacent Multiple tables
The concept of weights and the traversal of graphs
Weight value:
Graph traversal:
1. Depth-First search
2. Breadth-First Search
3. Minimum spanning Tree of graphs
1) Premium Manaus algorithm
2) Kruskal algorithm:
Iv. complementary points of knowledge
1. A review of the course:
The deepest feeling to me is:
1. First write the code ideas in Chinese, then one by one to write;
2. First think about the condition of the function end;
3. If the writing process, encountered some difficult to solve the small function, it is first functional, and then complete the function;
2. How to prepare algorithms and interviews
In addition to the daily algorithm exercises, for the small partners looking for work, how to better in the interview process in the algorithm to stand out or there are traces to follow. From the nine-chapter algorithm that can be summed up as follows:
1. The interview process should be properly communicated
2. Talk about your own understanding after you hear the question
3. Communicate the details of the issue with the interviewer
4. Tell the interviewer his own ideas or algorithms
Although the practice algorithm is biased towards the algorithm itself, good code style is necessary. The rough can be divided into the following points:
Code blocks can be three chunks: Exception handling (empty string and boundary handling), body, return
Code style (refer to Google's programming language specification)
1. Name of variable name (meaningful variable name)
2. Indent (statement block)
3. Spaces (operator side)
4. Code readability (even if the IF statement has only one sentence to add curly braces)
The reference given in the Code encyclopedia
In the process of the actual combat algorithm, we can take the following strategies:
1. Summary of similar topics in classification
2. Identify template programs suitable for the same class of topics
3. Master the basic problem
Data structure C + + version-figure