24 Principles of Computer programming

Source: Internet
Author: User

1, fatal abnormal termination will never allow

2, in this order to write: User manual, instructions, help, source code

3. Unless you use the Risk Factor analysis (RFA), a program will cost twice as much as you think the time required for development---duplication of work

4, the coding workload should not exceed the development work of 20%

5, the test should at least account for 30% of the project

6, note should be at least 20% of the source code

7. An error message should report what happened, what the user can do, what the program will do next, and which line of code is causing the problem? You may also want to pay attention to time, username and environment

8, the good program will automatically send the most recent error message to the permanent media

9, call a routine three times? Hide it call once? Don't hide

10, in addition to the menu and error traps, example thread precisely requires only one entrance and one exit

11, with a clear variable name and routine name of the document code

12, the database should be relevant

13, always use the best algorithm

14, first optimization of the slowest routines, using Profiler logo they

15. The best development language is usually the one with the shortest development time

16, require customers to sign the user manual and instructions

17, the first to write a more risky module

18, let the simple maintenance become the Guide your light

19. Check every signature and spelling you write

20, do not write any you can use a 3 * 5 card cover copy of the program

21, know when to finish what

22, no list is perfect

23, the difficulty is not what you are looking at

24, the existence of rules and laws can keep people from thinking

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.