concept primitive datum type in category java

appears as: primitive data types, primitive data types
Java SE 11 Programmer I Certification Guide

This is an excerpt from Manning's book Java SE 11 Programmer I Certification Guide.

Figure 4.2 Categorization of primitive data types
  • Primitive data types are the simplest data types.
  • OCA Java SE 8 Programmer I Certification Guide

    This is an excerpt from Manning's book OCA Java SE 8 Programmer I Certification Guide.

    Purpose: Note the type of the variable that’s passed as an argument to the switch construct. Among the primitive data types, you can pass on variables of types byte, short, char, and int to a switch construct. Other data types that you can pass to a switch construct are Byte, Short, Integer, Character, enum, and String.

    In this section, you’ll learn all the primitive data types in Java, their literal values, and the process of creating and initializing primitive variables. A variable defined as one of the primitive data types is a primitive variable.

    Primitive data types, as the name suggests, are the simplest data types in a programming language. In the Java language, they’re predefined. The names of the primitive types are quite descriptive of the values that they can store. Java defines the following eight primitive data types:

    Figure 2.2. Categorization of primitive data types

    2.1.4. Confusion with the names of the primitive data types

    If you’ve previously worked in another programming language, there’s a good chance that you might get confused with the names of the primitive data types in Java and other languages. For example, C defines a primitive short int data type. But short and int are two separate primitive data types in Java. The OCA Java SE 8 Programmer I exam will test you on your ability to recognize the names of the primitive data types, and the answers to these questions may not be immediately obvious. An example follows: