Algorithm first week of operation: Naming and book review

Naming rules:
avoid names appear numbered as func1 func2
name has exclusive sense of the word with the correct set of antisense
loop variable lowercase characters such as int i;
coding style:
each line at the beginning of the indent with the Tab
"IF", "for", "while", "do", "try", "catch" and other statements line by itself, the statement is executed not followed. Regardless of how much will be added to execute the statement "{}." This prevents mistakes when you write and modify the code.
In addition to special circumstances, the in vivo function can not appear two blank lines.
switch and case keywords should be aligned.
if the sub-variable case statement, {} contains up application.
If there is a similar statement juxtaposed simple case, consider the case of code blocks write a line of code.
Can no blank line between a simple case, consideration should be given separated by empty lines between the complex case.
Braces case word statement on a separate line, and do not row case wrote.
Provide default for all branches of the switch statement.
If a case does not need to break sure to add a comment declare
try not to use goto
when defining pointers and references * and & keep up type.
Avoid assignment in an expression used.
Avoid the floating-point type is equal to or do not equal judgment.
Enumerated types can not be assigned to operation after enumeration.
Do not modify the loop counter during cycling.
Detecting a null pointer, with if (p)
detecting non-null pointer, with if (!


Feedback mathematical beauty
of mathematical beauty by Google Institute of Wu in 2006-- wrote about during the 2008 primary mathematics in information retrieval and natural language processing of
articles lead role and fantastic applications. I was most impressed by this series is anti-Google search engine spam type articles.
Baidu's bid differs from search, Google uses advertising results on the right of the search bar so profitable model, which makes the Google search bar higher gold content than Baidu, so there will be some sites cheating. Some of them use duplicate keyword, that keyword on an inconspicuous area or decrease font size; others use their website is ranked in front of the mechanism links page impressions more than others, sold his own special display of cooperation links Links are no actual content sites and show a profit on the site. But first approach can easily be found in the engine itself, the second approach is easy to give himself away, over time cheating people is limited to the amount in a very low.
This shows that, regardless of search engine or some related software (such as games), you can use technology rather than manpower to identify some of the possible presence of cheaters. With the development of the times, cheaters will eventually be overcome technology, efforts to improve yourself is the best way to maximize the value of our life.

Guess you like

Origin www.cnblogs.com/lsshiwoa/p/11443643.html