Algorithm
A finite sequence of instructions that solves a problem or completes a task.
Basics
Compiler
A program that translates source code so it can run; reports compile-time errors.
Basics
Primitive type
int, double, or boolean; holds a value directly.
Data Types
Reference type
A type whose variable refers to an object (e.g., String).
Data Types
Variable
A named, typed storage location whose value can change.
Data Types
Expression
A combination of values, variables, and operators that evaluates to a value.
Expressions
Operator precedence
The order operators apply: * / % before + −.
Expressions
Integer division
int / int that truncates the quotient toward zero.
Expressions
Remainder (%)
The amount left over after integer division.
Expressions
Casting
Converting a value to another type with (int) or (double).
Casting
Compound assignment
Operators += −= *= /= %= that combine an operation with assignment.
Operators
Increment / decrement
++ adds 1 and −− subtracts 1 from a variable.
Operators
API
Documentation of the classes and methods available to a programmer.
Methods
Method signature
A method’s name plus its parameter types.
Methods
Static (class) method
A method called with the class name, e.g., Math.pow(2, 3).
Methods
Math class
Provides abs, pow, sqrt, and random static methods.
Methods
Object
An instance of a class.
Objects
Constructor
A special method run by new to initialize a new object.
Objects
Instance method
A non-static method called on an object with the dot operator.
Objects
Immutable
Unchangeable; a String’s contents cannot be modified after creation.
Strings
Concatenation
Joining Strings (or a String and another value) with +.
Strings