Coding Style and Comment — A Simple Guide for Beginner

Syntax

An ideal programmer should keep the eye on this coding syntax. Because it represents his/her personality how he/she is organized personally.

Curly Braces

Programmers use curly braces in JavaScript in ‘Egyptian’ tradition. We use the opening brace in the same line beside the declared keyword.

Line Length

Line length is another important thing that every coder should keep in mind. It is difficult to read long horizontal lines.

Indents

Every coder usually uses two types of indentation. One is horizontal and the other one is vertical.

Semicolons

Developers end every statement with semicolons. It is a good practice of coding. It helps us to avoid the possible pitfalls.

Style Guides

In every team of programmers, there are certain style guides. Such as they decide how many spaces they will use for indentation and what will be the maximum line length in characters.

Comments

Commenting in coding is a must for every programmer. There are two ways to comment in coding. One is a single line and the other one is a multiline comment.

An enthusiastic programming language learner. Love to live with coding. Travelling is the addiction. Nature is my mate.