Variables are used to store data. In JavaScript, you can declare variables using let, const, or var.
let name = 'John';
const age = 30;
JavaScript supports various data types, including numbers, strings, booleans, objects, arrays,and more.
let num = 42; // Number
let greeting = 'Hello, world!'; // String
let isStudent = true; // Boolean
You can add comments to your code using // for single-line comments or /* */ for multi-line comments.