I have a college classmate named Shi Lei, whom I have mentioned several times in previous articles, and we have worked together on many projects. As long as he is around, I am particularly at ease, because almost all difficult problems, to him, can be deftly solved. One of his most memorable words to me was, “What can’t be resolved? If you are willing to read the source code.”

Speaking of source code, I do not recommend novice to read, easy to discourage. No, you ask a schoolboy to read One Hundred Years of Solitude, and I guarantee he will lose interest in reading. Last year, I swallowed the first ten pages of this book, and then nothing — no more. I feel that I am still a little young, life experience has not reached that level, perception, internalization, thinking ability has not reached that level.

I recommend that programmers have at least one or two years of programming experience before reading source code, which is a good time. I was a junior out of the internship, that level really dare not flatter. Still, the company has some patience with us. More than 20 new people, divided into two groups, one group to make a calculator, the other group to make a drawing tool, two months to complete.

To put it bluntly, it is to assess us. If you fail, please withdraw. What I made was a calculator, and the finished product was later put on CSDN’s resource library, and I cheated a lot of C coins. To be honest, I copied and pasted some of the code from the Internet.

I worked on this part of the code for more than a month, but I didn’t understand it, only to say that I fixed a few minor bugs — and with this ability, I got a job that paid for me.

In the next year and a half, I did not force myself to read the source code, but followed the progress of the project team and accumulated programming experience. Just like kids, they have to learn to walk before they can run.

In 2012, I learned that Flex (a new generation of rich client technology combining the advantages of B/S and C/S technologies) would be the focus of the company’s future development, so I began to study the source code of Flex in the gap between projects. At this point, I felt like I was so good at copy-and-paste (or search engine oriented) that I was able to handle normal tasks, but still felt like A mess.

The overall framework of Flex is designed by Japanese personnel, which has made a layer of encapsulation on the original technology, with richer components, somewhat similar to the popular vue.js or React front end.

I was not involved in the Flex project at the time, but because I was close to a senior at the company, I asked him for the source code for a small project, built a local debugging environment, and started to “beat the weird upgrade”.

Have to admit that the Japanese developers write code or very rigorous, annotations more than code. My Japanese is not very good, but with the help of translation software and code awareness, I can dig into it.

A little disclosure here by the way. There are two source code authors to suzhou branch, I have seen them, at least in the age of more than 40 years old, according to colleagues, there are more than 50 years old, it seems to maintain good ah. They are very humble people (learning the essence of our nation) and are completely technical people – where are all the older programmers? Here’s the answer. As long as you’re skilled, companies need you.

After more than four months of unremitting efforts, I feel that my programming ability has been rapidly improved, not only can use the existing components of the framework, but also can expand some custom components when necessary – because I have read most of the source code, dare to touch the above.

In the meantime, I built a chat tool in Flex that I mentioned in an earlier post. The Spark chat tool used in the company is archived and cannot be used to discuss some non-work topics. For example, a few colleagues like to share their experience of World of Warcraft. This tool conveniently provides them with the server on my local computer.

It is by virtue of this chat tool, I was chosen by a leader, directly hired me to be the team leader, responsible for the coding part of the project. More importantly, a raise!

That’s why I’ve always felt that reading source code is an important skill — the ability to transform yourself from a code brick-remover to an engineer who builds wheels.

I now 8 years work experience, but a few years ago when came out, did not pay attention to the foundation, did not study the source code, now 30, feel pressure to come up. Lots of resumes, no interviews.

The above paragraph is the day before yesterday a reader Ann shao gave me the information, after reading, really pretty feel sorry for him. Although reading the source code is not a panacea, but to a programmer’s ability to improve, it is really very important, probably equivalent to internal work mind.

If Shao had settled down to “dive” or “swim” in the source code for a while early in his career (three or five years ago), he would not have worried about his future at the age of 30.

As anyone who’s ever interviewed for a Java job knows, interviewers like to ask questions about source code, such as, “What’s the underlying rationale behind HashMap? What if the size exceeds the capacity defined by the load factor?” If the usual willing to go to the source, these questions you must be able to answer fluently, otherwise it is really a face mengbi ah.

In summary, reading source code will not only improve your programming skills, but also help you to face the interviewer’s questions. By the way, I almost forgot that reading source code is a silver bullet for solving bugs.

This is one of the reasons why GitHub is so popular because the source code on it is open source. This means that if a bug occurs in a program that was caused by the source code, you don’t have to wait for the source code author to fix it. After all, the source code author has so many other important things to do that he can’t wait for you to issue online.

Remember I mentioned in the beginning of the article Shi Lei, he encountered a problem of the first reaction is to go to the source of the pants stripped bare. In his eyes, the source of the problem was either him or the source code, so I always thought he was a bit of a geek.

And I, usually, check their own code first, if you can’t find it, go to a search engine for help, if you can’t find it, will read the source code.

But if you want to grow, you can’t stay in your comfort zone all the time. You have to bite the bullet. When your head is hard (bald), it is really strong!

If you find this article helpful, please search “Silent King ii” on wechat and read it for the first time.

GitHub, portal ~, GitHub, portal ~, GitHub, Portal ~

I am the Silent King 2, a programmer with good looks but mediocre talent. Attention can improve learning efficiency, don’t forget three even ah, like, collect, message, I don’t pick, hee hee.