JavaScript Advanced Programming--Learn from scratch (2)

Source: Internet
Author: User

ECMAScript Foundation

1, grammar

Simple.

2, variable

Use the var operator to add a variable name definition.

If the variable name is not declared, the ECMAScript interpreter creates a global variable with the variable.

Using "Use strict" is recommended to develop good habits and always declare all variables.

3, original value and reference value

In ECMAScript, variables can hold two types of values:

(1) Original value: is a simple data segment stored in the stack, whose values are stored directly in the location where the variable is accessed.

(2) Reference value: An object stored in the heap, that is, the value stored at the variable is a pointer (point) to the memory of the storage object.

JavaScript Advanced Programming--Learn from scratch (2)

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.