首页 > 编程语言 >Java: Primitive and Non-Primitive Data Types

Java: Primitive and Non-Primitive Data Types

时间:2022-11-24 02:33:08浏览次数:44  
标签:Primitive Java type Non primitive Data types

  • Primitive types are predefined (already defined) in Java. Non-primitive types are created by the programmer and is not defined by Java (except for String).
  • Non-primitive types can be used to call methods to perform certain operations, while primitive types cannot.
  • A primitive type has always a value, while non-primitive types can be null.
  • A primitive type starts with a lowercase letter, while non-primitive types starts with an uppercase letter.
  • The size of a primitive type depends on the data type, while non-primitive types have all the same size.

 

标签:Primitive,Java,type,Non,primitive,Data,types
From: https://www.cnblogs.com/ShengLiu/p/16920683.html

相关文章