In computer programming, a **block** or code **block** is a section of code which is grouped together. Blocks consist of one or more declarations and statements. A programming language that permits the creation of blocks, including blocks nested within other blocks, is called a block-structured programming language. JavaScript is one such programming language.
A **block** statement in JavaScript is used to group zero or more statements. The block is delimited by a pair of curly brackets.