Java Programming thought note (operator)

Source: Internet
Author: User
Tags arithmetic operators bitwise bitwise operators

1. Simpler Print Statements:Print ();
2. Use the Java operator:1. The exception of the operator "=", "= =", "! = ", these operators can manipulate all objects. 2.String Support + =, +
3. Priority Level
4. Assign values:Direct manipulation of fields within objects can lead to confusion
4 (1). Aliasing issues in method calls
5. Arithmetic operators:Random rand = new Random (47);//stochastic generators always produce the same sequence of random numbers for a particular seed value
5 (1). Unary Plus and minus operators
6. Auto increment and decrement:++a (add first, then generate value); a--(Mister Value, then minus)
7. Relational operators:<, >, <=, >=, = =, = = Result is Boolean
7 (1). Equivalence of Test Objects
8. Logical operators:The and, or, or non actions can only be applied to a Boolean value. Short circuit
9. Direct constants:
9 (1). Exponential counting method:1.39e (-43) represents 1.39*10 (-43)//(-43) Index
10. Bitwise operators
11. Displacement Operator:<< (left shift operator), >> (right shift operator)
12. Ternary operator:If-else boolean-exp? Value0:value1//true calculation value0,false calculation value1
13. String operators:+ and + =
14. Errors often made using the operator:Bitwise AND, or (&, |) ; Logic and/or (&&, | | )
15. Type Conversion operators:Java allows us to convert any basic data type to another base data type, except for the Boolean type.

15 (1). Truncation and rounding:29.7 (29), Math.Round (29.7)//30

15 (2). Lifting

16.Java no sizeof

Java Programming thought note (operator)

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.