Come out and learn java2.

Source: Internet
Author: User

The composition of the Java language: Constant variable keyword, data integer size, variable use of the definition, the value is indispensable!  Constants are used in the same way, before using final. There are multiple data types, integer integers byte/short/int/long. 1248 bytes is the size. There are two decimal types, float/double are floating point, byte size four and eight. The Boolean type is logical, and the output is true and false. There is also a string, which can be read in both Chinese and English.

Integer size has a conversion: Large turn small strong turn, small turn large random turn, integer floating point no definition, automatic default int and double. Variable constants cannot be changed arbitrarily.

Variable constants are named, Fu Mingming have rules, the letter is the beginning, plus a dollar sign, the main is a kind of, 0 to 9 can be placed inside. Length size without rules, hump naming is the principle, the middle can not have spaces, see the name is the rule of understanding. The int Class studentsun=32 keyword is reserved: goto const is not available

operator expressions focus on the basics: incremental decrement is the top priority, ++--

1. Arithmetic operators

+: addition-: Subtraction *: multiplication/: Division%: Take in operation

2. Relational operators (you can only compare relationships between basic classes, and you cannot compare relationships between objects.) )

: Equals < <=: equals < >=: equals <

3, plus/minus/string connection

+   -     +

4. Shift Operators

<< >> >>>

5. Comparison operators

< <= > >=. instanceof

6. The bitwise operator

& | ^

7. Equality operators

==     !=

9, trinocular operator

? :

10. Conditional operators

&& | |

11. Assignment operator =

12. Extended Assignment operator

*=/=%= + = = <<= >>= >>>= &= ^= |=

Come out and learn java2.

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.