Home >Web Front-end >JS Tutorial >JavaScript Variables
is
let
const
var- is an old version after ES6
please repost...
can be reassigned...
var a = 5; e'lon qilish a = 6; qayta qiymat tayinlash mumkin var a = 7; qayta e'lon qilish mumkin
let- cannot be reposted...
can be reassigned...
let a = 5; e'lon qilish a = 6; qayta qiymat tayinlash mumkin let a = 7; qayta e'lon qilish mumkin emas
const- used for immutable data
cannot be republished...
cannot be reassigned...
const a = 5; e'lon qilish a = 6; qayta qiymat tayinlash mumkin emas const a = 7; qayta e'lon qilish mumkin emas
The above is the detailed content of JavaScript Variables. For more information, please follow other related articles on the PHP Chinese website!