Skip to content
techsnow

Introduction

Statements and Comments

A JavaScript program is a list of statements, run from top to bottom. Each statement usually ends with a semicolon.

let a = 5;
let b = 10;
let sum = a + b;
console.log(sum);

Output

15

Comments

// single-line comment

/*
  multi-line
  comment
*/