1, byte: 8 bits, the maximum amount of stored data is 255, and the range of stored data is-128~ 127.
2. Abbreviation: 16 bits, the maximum data storage capacity is 65536, and the data range is between -32768 and 32767.
3.int: 32 bits, the maximum data storage capacity is 2 to the 32nd power minus 1, and the data range is 3 1 power of minus 2 plus 3 1 power minus 1 of plus 2.
4.Long: 64 bits, the maximum data storage capacity is 2 to the 64th power minus 1, and the data range is -2 to the 63rd power minus 1.
5.float: 32 bits, the data range is 3.4e-45~ 1.4e38, and f or f must be added after the number in direct assignment.
6.Double: 64 bits, the data range is 4.9e-324~ 1.8e308, and the assignment can be added or not.
7.boolean: Only two values are true and false.
8.CHAR: 16 bits, storing Unicode codes and assigning values with single quotation marks.
Extended data:
Java is an object-oriented programming language, which not only absorbs the advantages of C++ language, but also abandons the concepts of multiple inheritance and pointers that are difficult to understand in C++, so Java language has two characteristics: powerful function and simple use.
As the representative of static object-oriented programming language, Java language perfectly realizes the object-oriented theory and allows programmers to carry out complex programming in an elegant way of thinking.
References:
JAVA_ Baidu encyclopedia