Posts

Showing posts from November, 2023

Document Object Model ( DOM )

Image
  DOM TREE

Object

Image
  Types of Objects :

4. Flow Control Statement / Decision Making Statement

Image
   Decision Making Statement Flow control statements in JavaScript are those statements that change the flow of execution in a program according to requirements and needs of the user. Types of Control Statements in JavaScript 1. Conditional statement 2. Unconditional statement 1. Conditional Statements in JavaScript :   A conditional statement in JavaScript is that statement that breaks the sequential flow of a program and jumps to another part of the code based on a specific condition. 1) If statement 2) If-else statement 3) Nested If-else statement 4) Switch statement 2. Unconditional Statements : An unconditional statement in JavaScript is that statement in which the flow of execution jumps to another part of code without carrying out any conditional test. It is also called unconditional execution in JavaScript. JavaScript supports three types of unconditional statements. They are as follows: 1) Break statement 2) Continue statement 3) Return statement 1) Break statement  - A break

2. Datatypes & Variables in Javascript

Image
Datatypes in Javascript 1. Comments There are two types of comments in JavaScript. They are as follows: 1. Single line comment (use // for single line  ) 2. Multiline comment (use /* */  for single line  ) 2. Data Types in JavaScript  - A data type in JavaScript specifies the specific type of value that a variable can store. In other words, a data type is simply a “kind” of value (i.e. data) stored in a variable. - Internally, a variable represents a memory location where data stores. Data is information that we store in computer programs. What is Dynamic Data Types in JavaScript ? JavaScript is a dynamic and loosely typed, or duck typed language.The value we assign to the variable determines its data type. JavaScript automatically handles different types of values and automatically converts values from one type to another. var FirstName = “Shubh” // Holding string. var AccountNumber = 123499 // Holding number. Types of Data types in JavaScript A list of all data types are as follows: