let hello = "hello"; console.log(hello); //Result: //hello console.log(hello.length); //Result: //5 /** * Let's split string into array to check index * */ console.log(hello.split("")); //Result: /** * 0: "h" * 1: "e" * 2: "l" * 3: "l" * 4: "o" * */ /** * Examples of using double quotes, single quotes and backticks * */ let firstString = "String 1"; let secondString = 'String 2'; let thirdString = `String 3`; let withQuotesInside = "String of a 'string'"; let withSQuotesInside = 'String of a "string"'; let withBackticks = `String of a 'string' of a "string"`; /** * Concatenation example * */ console.log(firstString + ' ' + secondString); //Result: //String 1 String 2 console.log(firstString + ' ' + thirdString); //Result: //String 1 String 3 console.log(`${firstString} ${secondString} and finally the ${thirdString}`); //Result: //String 1 String 2 and finally the String 3