Module 2 Flashcards
This module will teach you how to program using different data types and keyboard inputs. Specifically, Declare and use constants and variables Use integer data types Use the boolean data type Use floating-point data types Use the char data type Use the Scanner class to accept keyboard input
Cannot be changed while the program is running
For example, System.out.println(459);
CONSTANT
The value that is taken literally at each use.
LITERAL CONSTANT
As opposed to a literal constant.
NUMERIC CONSTANT
No identifier is associated with it.
UNNAMED CONSTANT
Instead of using constant data, you can set up a data item to be _________.
VARIABLE
A named memory location.
VARIABLE
Used to store a value.
VARIABLE
Can hold only one value at a time.
VARIABLE
Its value can change.
VARIABLE
A type of data that can be stored.
DATA TYPE
It refers to how much memory an item occupies.
DATA TYPE
A Data item’s _________ defines the type of data that can be stored there, how much memory the item occupies, and what types of operations can be performed on the data.
DATA TYPE
2 Main Data Types in Java
- PRIMITIVE TYPES
2. REFERENCE OR CLASSES TYPES
8 Primitive Data Types in Java
- BYTE
- SHORT
- INT
- LONG
- FLOAT
- DOUBLE
- CHAR
- BOOLEAN
Are data types considered basic to Java.
PRIMITIVE TYPES
Are more complex data types which hold memory addresses.
REFERENCE OR CLASSES TYPE
The keyword for a byte-length integer.
BYTE
The keyword for a short integer.
SHORT
The keyword for integer.
INT