J2SE Base-1

Source: Internet
Author: User
Tags float double

1.java identifier: hellworld--Hello world can not space DataClass--dataclass# # _983--98.3 digits start. $bSS 5_C7--Class keyword

2, keyword class void goto const

3.JAVA constant "123" ' a ' 3.34 true,false;

4.java variable final int i = 100;  Type varName [=value][,varname=value]; Local variable/member variable basic/reference variable Testvar.java

5. Data type: base data type numeric integer byte short int long float float double character type (char) Boolean (Boolean) reference data type class interface Interface array

6 logical Boolean literal char java takes a Unicode integer byte short int long occupies a storage space table number range fixed not affected by the operating system floating-point float double

Double d = 3.1415;      float F = 4.5f; Testvar2.java

7. Conversion of basic data types from small to large (from large to small need to add coercion type conversion) Testconvert.java method ();

J2SE Base-1

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.