When you start learning JavaScript first you should know data types and keyword because these are building block of coding
What is JavaScript?
JavaScript is programming language of the web.
It can update and change both HTML& CSS.
It can calculate , manipulate and validate data
JavaScript Keywords for Variables:
*Key words 4 types *
var, let, const, without keyword
var: variable is identifies and reference it can change redeclared and updated. And its function Scoped
*example: *
Tamil: 99;
English: 50;
Math’s: 70;
If it can change the marks (Tamil:80;)
let : Cannot be redeclared, but can be updated.
Block-scoped (limited to {} where it is declared).
example :let age = 20;
age = 25; //
// let age = 30; (cannot redeclare)
const : Used for values that should not change.
it is standard its block-scoped
example:
const i = 10;
i = 15;(cannot update )
Without Keyword :
If you assign a value without var, let, or const, JavaScript
will automatically create a global variable (not recommended).
JavaScript Data Types
There are two types of Data Types
*Primitive Data Types
*Non Primitive Data Types
What is Data types (Data its Information):
data types defines the kind of value we store in a variable can hold. JavaScript is a dynamically typed language
*primitive data types
* (String, number, Boolean, BigInt, Symbol, Undefind, null)
Number: 10,2.15
String : “abc”
Boolean : true or false
Undefined : variable declared but not assigned
Null : intentionally empty
Symbol : unique value
BigInt : large numbers beyond Number range