My programming path (19th): some details and inspiration in development;

Source: Internet
Author: User

My programming path (19th): some details and inspiration in development;

1. js namespace

If you write background code, layering is the basic knowledge of the subconscious, but when you arrive at the front-end, there is no such awareness. In the end, JavaScript is not used much, and you have never cared about the status of js, until now, the trend and requirements of rich clients have made many codes need to be completed in front-end using js or its framework. Therefore, the management of js Code should be as standardized as that of background java code, the namespace is a package, which is also used to manage different levels of code.

2. Closure

A closure is a function that can read internal variables of other functions. It has two major functions: one is to read the internal variables of the function, and the other is to keep the values of these variables in the memory.

For details about the closure analysis, refer: Javascript: a deep understanding of js closures

3. objectization, componentization, MVC \ MVVC

Object-oriented: object-oriented development (js)

Componentization: extract common functions (html, Ext. component, etc)

4. Familiar with Apis

In the past, I thought that my knowledge was wide. As for some technical details, especially some APIs, I did not care about it. The actual development, especially the development efficiency, is directly related to your api familiarity. In many cases, the problem can be easily solved. Because you are not familiar with the api, you may need to write a lot of code to implement it yourself, and may also put a lot of effort into hidden bugs in the future ···

5. Regular Expression

I have never paid much attention to regular expressions before. Some user input is often verified during development a few days ago. As the saying goes: never eager for users to enter regular expressions as required ···, therefore, you need to consider a lot of input that you may not want to think about, so the front-end verification is particularly important, especially when the value is transferred to the background, it may be blank, or a number, or separate them based on some characters. The regular expression at the front end can simplify troubleshooting and judgment of many background exceptions.

6. EXT:Form submit method, Ext. ajax. request method. It is recommended that you do not upload the action, method, and params together with the url when passing the parameter. You are advised to use the params attribute and Ext. applyTo ({}) assembles parameters into objects for parameter passing, obtains arrays in the background, and uses request. getParameterValues ()

7.Write the div in the html attribute instead of the jsp page: prevent the component in the closure from finding the corresponding div

8.Debug js Code in Visual Studio2008: in IE browser-tools-options-advanced-check "Disable script debugging", and then add "debugger" to js Code ", after running, open vs2008 according to the dialog box

9.Use spring jdbcTemplate to query and use preprocessing statements. What should you replace? In a fuzzy query, you can use the following code to solve the conflict: like '%' |? | '%' Or? Is null

10. Conflicts between team members during development:

Programmers do not know how to behave. Because their personalities are straight, they usually offend others and have a fatal problem: they think they are always right, so I always point my mistakes to others. Today I deeply understand this point. I am too impatient to pay attention to it. I can only prove that the problem is not here. Even if your voice is too loud, it sounds reasonable. I can prove it to you. I have something to say: the bottle is full, half a bottle. This is an alarm for everyone, especially those who have no practical ability but are self-righteous ···




Books that inspire Programming

The art of programming written by Knuth
The Mythical man-month written by Brooks

The art of Unix Programming
Inside C ++ reference model written by Stanley

I think a lot of things, but I have not seen much.

I have learned the basics of C language, and then I will program it to a level like the library management system. What kind of books should I read later? Details

If you can go back to the past, as a developer, you can tell yourself that you should read a book in the early stages of your career. Which one would you choose? I hope this book list is rich in content and can cover many things ."
1. Code Daquan Steve Mike Cornell
Recommendation: 1684
"An excellent Encyclopedia of programming practices," code Daquan "focuses on personal technologies. All of these are what we say by instinct:" writing clean code ". This book has 50 pages to talk about code layout ." -- Joel Spolsky
For beginners, the concepts in this book are somewhat advanced. By the time you prepare to read this book, you should have known and practiced 99% concepts in the book. -Esac
Steve McConnell's original code book (version 1st) is recognized as one of the best practices for programming. Over the past decade, this book has been helping developers write better software.
Now, the author has integrated this classic book into the cutting-edge practical technology and added hundreds of new code examples, fully demonstrating the artistic and scientific nature of software building. McConnell brings together the main knowledge from research institutions, academia, and the daily practices of the industry, and integrates the most efficient technology with the most important principles into this clear and practical guide.
Regardless of your experience, development environment, or project size, this book will inspire your thinking and help you build high-quality code.
Code Daquan (version 2nd) has been comprehensively updated, adding a lot of content that keeps pace with the times, including discussions on new languages, new development processes and methodologies.

2. programmer Cultivation
Recommendation: 1504
This is an excellent book for programmers who have learned programming mechanisms. Maybe they are still in school, but they do not feel very safe about what they want to do.
Just like the difference between sketch and architecture. Although you learned drawing in school classes, you can also draw beautiful pictures, but if you don't know where to start, if someone wants you to draw a P2P Music Exchange Network Diagram on your own, this book is suitable for you. -- Joel
Introduction to "Programmer cultivation path: from small workers to experts": "Programmer cultivation path" consists of a series of independent parts, covering the subject from personal responsibility, career development, learn about the various architecture technologies used to keep code flexible and easy to adapt and reuse, and use entertaining anecdotes, thoughtful examples, and interesting analogy, it comprehensively explains many different aspects of software development best practices and major traps.
Whether you are a beginner, an experienced programmer, or a software project manager, "Programmer cultivation: from a small worker to an expert" is suitable for you to read.

3. Construction and interpretation of computer programs
Recommendation: 916
Personally, this book has so far become a fascinating programming book for me.
Classic books such as code Daquan, refactoring, and design patterns will teach you efficient work habits and transaction details. Other books such as the collection of pieces, computer programming psychology, and The Mythical man-month will go deep into the psychological layer of software development. Other Books process algorithms. These books have their own locations.
However, the construction and interpretation of computer programs are different from those. This is a book that will inspire you. It will inspire your enthusiasm for writing excellent programs. It will also teach you to know and appreciate the beauty. It will give you a kind of reverence, it makes it hard for you to suppress the desire to learn more.
Other books may make you a better programmer, but this book will surely make you a programmer.
At the same time, you will learn other things, functional programming (Chapter 3), inert computing, metaprogramming, virtual machines, interpreters, and compilers.
Some people think this book is not suitable for beginners. I personally think that although I do not fully agree that I must have some programming experience to read this book, I must recommend it to beginners. After all, this book is written to the famous 6.001 and is an introductory Programming Course at the Massachusetts Institute of Technology. This book may require more effort (especially when you are doing exercises, you should also do so), but the price is worth it.

4. C Programming Language
Recommendation: 774
This book is concise and easy to read. It will teach you three things: C programming language, how to think like a programmer, and the underlying computing model. (This is very important for understanding the "bottom layer"... the remaining full text>
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.