Simple but not remembered

Source: Internet
Author: User

%: If there is a decimal number and it is not an integer multiple, the result may not be as expected. Reason: it is related to the computing precision.

Example: 13.1% 5 gets 3. 0999... 6 instead of 3.1.

6.2% 3.1 get 0, no problem

= Judgment: Data of the value type, which determines whether the value is equal. The reference type determines whether the reference is the same. Java and C # Always judge whether the reference is the same. Nan and any value are not equal, even if it is itself

= Judgment: Based on =, the type judgment is added. True is possible only when the types are identical.

> Judgment: when the operation object on one side of the operator is a value type and the other side is not a value, it is first converted to a value type and then determined. If the conversion fails, the value is always false.

Function: Two declaration Methods: expression declaration, common declaration, function parameter array arguments. callee holds the reference of the current function

Tips for using functions: You can determine which function to call based on parameters.

Example:

 VaR  Fun: function;  VaR Sex: String ="  Male  "  ;  If ( "  Male  " = Sex) {fun = Malefunc ;}  Else  {Fun = Femalefunc;} fun (); function malefunc () {trace (  "  Male  " );} Function femalefunc () {trace (  "  Female  "  );} 

 

Loop: The Goto label is not supported, and the continue and break labels are supported.

 

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.