+
Naming Variables

Recently, I watched Douglas Crockford's talk regards to JavaScript's EMCAScript 7. It was the first time that I listened to a programmer's speech. It was brainstorming. I learned from him that how should I learn a programing language. On the other hand, he mentioned how important to name variables meaningfully. For both your own and your colleagues' benefits.

A lot of professional programmers mentioned the importance of naming variables mean that many junior or even senior coders don't pay close attention to name variables. Thus, we should build the habbit to name variables meaningfully since we learn programming.

This Wednesday, I also had the chance to listen to Michael Mikowski's speech. He said many programmers who came from Ruby, prefer to naming variables in "var houses" in JavaScript, which is very confused for the other colleagues or the future yourself to know, whether "houses" is an int, or an array. If you want to create a variable of "houses", you can name it "var house_list", so other people will know it's an array of a list of houses. How important is this? For example, your colleagues don't need to look up the original file to check what variable it is.

Thus, I believe naming variables without meaning is an issue exists in Tech Industry. As a newbie, I should build a good habbit to name variables meaningfully to avoid future inconvenience.