3.java Getting Started fourth chapter

Source: Internet
Author: User

1.equals to determine if strings are equal

2.switch statement: (1) The parentheses after the switch must be integral or character type;

(2) The case must be followed by a constant, such as 1,2+2, ' a ', and a single quotation mark;

(3) The case of the same function can be merged:

(4) The default block can appear in any position, or can be omitted;

3.java Loop statement: While, Do...while, for

While: first judgment, after execution Do...while: first execution, after judgment

For loop variable initialization and cyclic variable change parts, you can initialize or change the values of multiple loop variables simultaneously with ', '

4.break: Directly jump out of the current loop, execute the statement after the loop statement;

5.continue: End the loop and jump into the next loop;

3.java Getting Started fourth chapter

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.