The programming instructions written in a program in a programming language are known as statements. The order of execution of Statements is the same as they are written.
- Multiple statements on one line are allowed if they are separated with a semicolon.
3. White Space:
document.getElementById("geek1").innerHTML = "Hello Geek!";
Some commonly used keywords are:
- break and continue: break keyword is used to terminate a loop and continue is used to skip a particular iteration in a loop and move to next iteration.
- do…. while: In this the statements written within do block are executed till the condition in while is true.
- for: It helps in executing a block of statements till the condition is true.
- function: This keyword is used to declare a function.
- return: This keyword is used to exit a function.
- switch: This helps in executing a block of codes depending on different cases.
- var, let and const : These keywords are used to declare a variable in js.