Software development experience (2) Don't let the mindset hurt you

Source: Internet
Author: User

In some software companies, there are always some "high people" who never write documents, do not design, and do not write comments on code, after talking a few times with users, they began to write code, and their code was not understood by ordinary people. After countless bugs were changed, the system they developed was launched, after numerous times of abuse by users, the system also becomes more and more stable. The system has become the most important product of the company. If ordinary people want to understand the system, they must explore its Code for 10 years and 8 years, what is the idea of "Design Pattern and layered structure"? In these companies, everything is done as long as users can be done.

At the beginning of each new project, the boss always said to the project team, "Our system is Jinbaoshan, which has spent so many resources of the company and has passed the multi-layer test of users, all are the essence. If any module in your project is similar to it, it will be used directly." Programmer B did not listen to the boss and designed a set of good algorithms to solve the business problem. Finally, he scolded the boss for a small bug in the system, I had to leave my job, worked hard for a year, and lost my year-end bonus. Programmer A has listened to the boss's words and done everything according to the old system model. Even if the user is not satisfied, the boss will solve the problem through some other means. Finally, programmer A became a project manager and started to be "nine thousand" in the company. Every time he met someone, he said that the old system was really good! Since then, everyone has learned what algorithms and organizations are doing according to the methods of the old system. Even if it is wrong, it is not their own responsibility. Everyone no longer thinks about it, it is correct to follow the old system. There must be more bonuses at the end of the year.

After many years, from a habit to a tradition, from a tradition to a culture, there is always a shadow of the old system in every system, the boss always says to people, "Our system is about to surpass India, and all programmers write almost the same code." Open every piece of code and you will always see this code culture:

(1) When writing SQL statements, select always follows *, and no one will think about why.

(2) When writing SQL statements, if you need to connect two tables, you must use left join. No one will use inner join or right join.

(3) An object must always be instantiated (such as datatable obj_dt = new datatable ).

(4) When you execute 100 SQL statements, you always need to connect to the database for 100 times.

(5) All methods of the system always use public, even if they are called by themselves in the class.

(6) The code is always encrypted (the variables are all defined as odd and strange, even if others get the original code, they cannot understand it ).

(7) stored procedures are never used. They only use strings to spell SQL statements in the code and then execute them.

(8) The Code cannot be understood if it has not been touched for 3-5 years.

(9) database indexing is always unnecessary (if the customer finds it slow, let the customer change the machine)

(10 ).............

 

 

Of course, this is just a common joke, and it may not exist in reality. However, many developers may have some fixed mindset when developing and regard what they know as all, never think about why, nor do you think about better solutions. If you eat your old development system all day without learning new things, it will be eliminated by society one day!

After so many things, I want to remind myself that I should think about the best way of this solution during development? I don't know if there is a better solution. Is there any defect in this solution? At ordinary times, we should learn more excellent code written by others, learn more new knowledge, and let the Fixed Thinking be deleted from my dictionary, and share it with the brothers in the garden!

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.