Ten effective ways to be a good programmer

Source: Internet
Author: User
Keywords Programmers become they others
Tags aliyun basics check code core technology crosses design find

http://www.aliyun.com/zixun/aggregation/7026.html "> Outstanding programmers are people who look to both sides as they cross a one-way street.

As a software programmer in the IT industry, the day-to-day hard work that drives us day by day comes from our interest and passion in programming. But to make programming always fun, we must learn to stick to some of the basics of being good programmers.

I'm not trying to write a few spells, but you can be a good programmer by executing it. My purpose is to record some useful lessons I have learned and used to help me get better results. There is no clear definition of good programmers, and here we are referring to those who created good IT solutions and helped grow the industry.

Grasp the basics

Co-ordination is the key to success for any job in any industry. A person who wants to be a good programmer must have a solid foundation. The understanding of the core concept will help you to design and implement the best solution in the best way. If you feel you can not grasp the core of computer science or the knowledge of a programming language, it is not too late to start reviewing the basics now.

1. Start tagging your code (what to do and what to do)

I've found a clear line of distinction between good programmers and ordinary programmers, and good programmers are eager to find out what each line of code has done and how it can be done. So a small group of people, they must understand each line of code. I know that when time is tense, we often can not follow this principle, just write some code to know that it has achieved the required functionality. How to deal with this situation is another topic, but as a programmer, we often have to explore as much as possible. Believe me, this will become a habit over time, and every time you unknowingly do this.

2. Help others, you can learn more

Many people have a common denominator, and he only resorts to forums or groups when he needs help. The difference between good programmers is that they often browse the forum to help others. They help others learn more by helping others solve problems than by others. The same is true in a team, helping others solve problems more. Believe me, learn about other people's problems, think about it, and ultimately provide solutions. You learn more than before.

Write simple, logical code

Just as the KISS principle (keeping it short) applies to all aspects of life, it also applies to programming. Try to write logical code to avoid complication. Sometimes people write complex code just to show that they have the ability to write such code. My experience tells me that the simple and logical code is very good, will produce fewer problems, but also easier to expand. I remember one sentence:

Good code itself is the best document. When you want to annotate, ask yourself, "How can I improve my code to read and understand without writing a comment?"

Spend more time analyzing the problem, you will spend less time to solve the problem

Spend more time understanding and analyzing the problem before you design the solution. You will find the rest easy. Design does not mean using modeling languages ​​and tools, it's just a matter of seeing the sky in mind. Those who start typing code in the face of a problem tend to eventually deviate from the demand.

If you can not sort through the structure of the whole program when you bathe, you are not ready to start programming yet. - Richard Pattis

Be the first to check your code

Although it's a little harder, try modifying it before others change your code, and over time you will write almost bug-free code. Check your code without any prejudice, and do not hesitate to let other people check your code. Working with other great programmers and accepting their opinions helps you to grow as a good programmer.

6. Do not get lost in a rapidly changing technology world

In the IT industry, I often meet many people who are dissatisfied with their current jobs and even leave it to pursue new jobs because they want to learn the latest technology. Every day we hear new tools, interfaces, frameworks that make the process easier and faster. This is common in the tech world and will always be. But the most basic and most central technological change is much smaller than those of frameworks, tools, and interfaces. Like the sea, waves tumble on the surface of the sea, but the depths of the sea are quite calm, and where is the aquatic life. So put yourself in the depths of the core technology bar. For example, in Java enterprise applications, new frameworks appear every week, but the core technologies are the same, based on client-server requests, MVS patterns, filters / servlets / JSPs, data sources tied Set, XML parsing, and more. Instead of worrying about the emergence of ever-changing frameworks and tools, take the time to learn the core concepts. Believe me, with the basics of core technology, you find it easier to learn new frameworks, tools, and interfaces.

7. Contingency plans do not last long

Very often software gurus will adopt contingency plans (which may not be enough time, may not understand the problem is not thorough or lack of experience). However, this often results in confusing code, lack of scalability and maintainability, and wasted more time. Please implement the plan after you understand it clearly. I know that in some situations the contingency plan is inevitable, as if one should be honest, but you have to lie in some cases.

8. Read the document

Reading a lot of documentation is one of the must-have habits for good programmers. May be product manuals, JSR, API documentation, tutorials and more. Reading documents helps you get the basics necessary to write better code.

9. You can learn the code of others

I've worked with some great programmers who have been using JAVA source code in their IDEs and have often read and consulted in their daily work. They do so not only to satisfy the desire to know, but also to learn how to write good programs. Read and consult reputable open source code that you consider reliable or code better than your experienced programmer, and you'll be able to write better programs. (Extended reading: "Reading good code is a quick way to improve developer productivity.")

Finally, I want to say but did not list it: Do not compare with others

Comparisons with others often result in negative emotions and unhealthy competition. Everyone has his strengths and weaknesses. It is important to avoid weaknesses. I often see some very basic programmers very low level error. So just compare yourself with what you need to improve and keep improving it. Programming is a very interesting thing to enjoy it.

Any fool can write programs that computers can understand, and good programmers write programs that others can read.

Related Article

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.