17 February 2021

let example in javascript

  let: The let statement is used to declares a variable in JavaScript. Let introduced from ES2015.

 JavaScript Code:

let myName='Adi';

console.log(myName);


myName='JC';

console.log(myName);

Output:

"Adi"
"JC"

No comments:

Post a Comment