Java to learn the first day of Section 4 (data type)

Java data types are divided into two categories: basic data types and reference data types

1. Basic data classified into eight types, i.e. byte (byte), Short (short integer), Int (integer), Long (long integer), single precision floating point (a float), double precision floating point type (double), character (char), boolean (boolen)

2. Reference Data Type: String (String), Array (arrays), class (category), interface (interface)

 

Note: The characters and strings are two different types. Character single quotation marks ( ''), a string double quotes ( "")

When using printlnl input, double quotes may be empty, can not be null single quotes. A character, and only one character.

Guess you like

Origin www.cnblogs.com/vxiao2/p/11470598.html