How to Choose the Correct Programming Style


show more What should you name your variables? When should you comment? How should you break up lines? These are not questions that affect your code's functionality, but they make it easier for other people to understand your JavaScript code. In this Lynda.com training video, you will learn the main elements of naming conventions and programming style. show less
please wait ...

Programming style

When we talk about style with programming languages, we're moving away from the rules, the syntax of how you must and must not write your code, into more of how you should and shouldn't write it. Now, we've talked about this a little already. It's things like what should you call your variables, what's the best place to put your curly braces, what should you call your functions, and where should they go in your code. Now all programming languages develop accepted style guidelines. There's often a lot of debate over what should be the right way to do things but even with a disagreement, they're still really useful.

The main point of style guidelines is that you want your code to be readable, you want it to be consistent, and you also kind of need to play along with how everyone else in the world is writing that language because that's going to make it easier to read example code and read books and to recognize whether the code you're looking at is writte...

Programming style
Video duration: 5m 55s 4h 47m Beginner

Viewers:

What should you name your variables? When should you comment? How should you break up lines? These are not questions that affect your code's functionality, but they make it easier for other people to understand your JavaScript code. In this Lynda.com training video, you will learn the main elements of naming conventions and programming style.

Subjects:
Developer Web
Author:
please wait ...