Curriculum
Course: JavaScript Basic
Login

Curriculum

JavaScript Basic

JSHome

0/216
Text lesson

JavaScript is Case Sensitive

In JavaScript, all identifiers are case sensitive.

Thus, the variables lastName and lastname represent distinct entities.

let lastname, lastName;
lastName = “Doe”;
lastname = “Peterson”;

JavaScript does not interpret the words LET or Let as the keyword let.

JavaScript and Camel Case

In the past, programmers have employed various methods to concatenate multiple words into a single variable name, such as using hyphens:

For example: first-name, last-name, master-card, inter-city.

In JavaScript, hyphens are reserved for subtraction and thus cannot be used within variable names.

Underscore:

first_name, last_name, master_card, inter_city.

Upper Camel Case (Pascal Case):

FirstName, LastName, MasterCard, InterCity.

Lower Camel Case:

In JavaScript, programmers commonly utilize camel case, beginning with a lowercase letter.

firstName, lastName, masterCard, interCity.

JavaScript Character Set

JavaScript employs the Unicode character set, which encompasses nearly all characters, punctuations, and symbols worldwide.