4 kinds of 8 kinds of basic data types reference data type
//parking - & gt; Variable che - & gt; Data
Car of different size, different data types play
Variables: is likely to change the value of the
During the program is run, its value can change the amount of
Open up a piece of space, in memory space used to store the specified type of data
Before defining variables, is clear about the type of store data
Definition: a statement at the same time assignment: data type variable name=assignment;
First sound next assignment: data type variable names; The variable name=assignment
Common data types: int positive double decimal String String "any character"
Char character type a character 'X' Boolean Boolean (true or false true/false)
Basic data types: integer - byte type byte 1 byte=8 bit (bit)
Short integer: short + - 30000
Integer: int + - 2.1 billion
Long plastic: long very large
Floating point:
Single precision float down to the decimal places around seven
Double double precision to about 15
Character:
Char said individual characters' one character '
Boolean:
Boolean true/false is not true is false
Reference data type: the class interface array []
CodePudding user response:
Do you want to do? You want us to help you write the code? Let's see you write the code for you? Do you want to directly say