--A brief introduction to several recently popular languages and their basic data types. Compare the difference! ! In fact, friends who have learned these three languages know that most of them are the same, but there are a few different types. The following is my own summary:
The first one: C language
1. The basic types are divided into: numerical type and character type char.
Numerical type is divided into: integer, floating point.
Integer is divided into: short integer short, Integer int, long integer long.
Floating point is further divided into: single-precision float, double-precision double.
2. The structure type is divided into: array, structure struct, union union, enumeration type enum.
3. Pointer type
4. Empty type void
The second: C++ language
1. The basic type is added on the basis of C: Boolean bool. (char, short, int, long, float, double)
Boolean has only two values: false , true;
2. Constants are divided into: integer constants, real constants, character constants, string constants, Boolean constants, etc.
3. Variables are quantities whose values can change during execution. The
third type: Java language
1 .Numerical type is added on the basis of C: byte type byte (char, short, int, long, float, double)
2. Logical type boolean. The
logical type has only two values: false, true;
This is my personal opinion...
Basic data types in C, C++ and Java languages
Guess you like
Origin http://43.154.161.224:23101/article/api/json?id=326485842&siteId=291194637
Recommended
Ranking