Simple Data Types

dreamstime_s_28161693 Data

Most programming languages support at least four simple data types:

  • Character: a single letter, digit, special character or control character
  • Integer: a whole number
  • Floating point: a number with a fractional part, sometimes referred to as a real number.
  • Boolean: a logical data type that can only take the values True or False.

In this course we’re going to use the Java programming language. Java calls simple data types Primitive Data Types. It supports a single character data type (char), three integer data types (byte, short, int and long), two floating point data types (float and double) and a single Boolean data type (boolean). We’ll look at each of these more closely in the following sections.

You can view a short video on Java Primitive Data Types here.

Next: Character