JavaScript Language Basics 8

Source: Internet
Author: User

This article is a summary of the knowledge of the previous study:


1. JavaScript supports a variety of data types, such as numeric types, string types, Boolean types, and so on.


2. In JavaScript, a string is a series of characters enclosed in quotation marks, which can be used to denote special characters that cannot be entered directly.


3. In JavaScript, variables are used to store data such as numeric values or strings in memory, and data stored in variables can be accessed at any time through variables in the code.


4. Variable names cannot contain certain illegal characters, nor can they contain javascript reserved words.


5. JavaScript has 4 basic arithmetic operators, plus (+), minus (-), multiply (*), and divide (/). Assigning a value to a variable is also called an assignment operator, using the equals (=) operator.


6, the operator has precedence.


7. In JavaScript, a new string is formed by connecting the string together (+). If the value and character are concatenated with the + operator, JavaScript automatically converts the value into a character.


8, JavaScript can be automatic type conversion, but in some cases, you need to use the cast, such as the previous parseint () and parsefloat (), you can convert the corresponding string to the corresponding value, for the string cannot be converted, return a Nan value.


9, the array is a special variable, consisting of multiple array elements, you can maintain a number of different types of data, the index of each array is unique, through the index can assign a value to the specified array element, or access the specified element.



Reprint Please specify source:http://blog.csdn.net/hai_qing_xu_kong/article/details/41154237 Emotional Control _


JavaScript Language Basics 8

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.