1/177
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
@Override Annotation
An optional annotation placed before a method to indicate that it is intended to override a method in the superclass; causes a compile-time error if no matching superclass method exists.
Abstract Class
A class declared with the abstract keyword that cannot be instantiated directly and may contain both abstract methods (no body) and concrete methods (with body).
Example: "abstract class Shape { abstract double area(); } defines a class that cannot be used directly."
Abstract Method
A method declared with the abstract keyword and no body in an abstract class, forcing every non-abstract subclass to provide its own implementation.
Example: "public double area(); must be implemented by every non-abstract subclass."
Abstraction
The process of hiding implementation details and exposing only the essential features of an object, reducing complexity and isolating impact of change.
Access Modifier
A keyword that controls the visibility and accessibility of a class, constructor, variable, or method; includes public, private, and protected.
Accumulator
A variable used inside a loop to build up a running total or combine values over multiple iterations.
Example: "int sum = 0; sum += arr[i]; — here sum is the that collects the total."
add(int index, Object element)
An ArrayList method that inserts a specified element at a designated index, shifting subsequent elements to the right.
add(Object o)
An ArrayList method that appends a specified element to the end of the list.
Algorithm
A step-by-step set of instructions for solving a problem or accomplishing a task.
Arithmetic Operator
An operator that performs mathematical operations: +, -, *, /, % (modulo).
ArithmeticException
A runtime exception thrown when an arithmetic error occurs, most commonly integer division by zero.
Array
A fixed-size data structure that stores multiple elements of the same data type in contiguous memory, accessed by integer indices starting at 0.
Example: "int[] scores = new int[10]; declares an that holds ten integers."
Array Declaration
Specifying the data type and variable name for an array using square brackets.
Example: "int[] arr; is an for an integer array."
Array Initialization
Allocating memory for an array using the new keyword and specifying its size.
Example: "arr = new int[5]; performs by reserving space for five integers."
Array Length
The number of elements an array can hold, accessed via the .length field (not a method call).
Example: "scores.length returns the of the scores array."
Array Literal
Directly assigning values to an array using curly brace notation without using new.
Example: "int[] arr = {1, 2, 3, 4, 5}; is an that creates and fills the array at once."
Array Traversal
Accessing each element of an array in sequence, typically using a loop from index 0 to length-1.
ArrayIndexOutOfBoundsException
A runtime exception thrown when an attempt is made to access an array element at an invalid index (less than 0 or greater than or equal to length).
ArrayList
A resizable array from the java.util package that dynamically grows or shrinks as elements are added or removed; stores object references, not primitives.
Example: "ArrayList<String> list = new ArrayList<>(); creates an of strings."
Assignment
Using the = operator to give a variable a value (initial or updated).
Example: "x = 10; is an that stores the value 10 into x."
Autoboxing
The automatic conversion of a primitive type (like int) to its corresponding wrapper class object (like Integer) when added to a collection.
Base Case
The condition in a recursive method that stops the recursion and returns a value without making another recursive call; prevents infinite recursion.
Behavior
What an object can do; represented by the methods defined in its class.
Binary Search
An efficient searching algorithm that repeatedly divides a sorted array in half, comparing the target to the middle element to narrow the search space; O(log n) time complexity.
boolean
A primitive data type that can only store one of two values: true or false.
Example: " passed = true; declares a variable that holds a true/false value."
Boolean Expression
An expression that evaluates to either true or false, typically using relational and logical operators.
Example: "x > 5 && x < 10 is a that checks if x is between 5 and 10."
Bubble Sort
A simple sorting algorithm that repeatedly compares and swaps adjacent elements that are in the wrong order until the array is sorted; O(n²) time complexity.
Call Stack
A data structure that tracks active method invocations; each method call adds a new frame, and each return removes one. Recursive calls grow the stack until a base case is reached.
catch Block
A block of code that handles a specific type of exception thrown within the associated try block.
char
A primitive data type that stores a single character, enclosed in single quotes.
Example: " grade = 'A'; stores a single letter in a character variable."
Class
A user-defined blueprint or template from which objects are created; defines the state (fields) and behavior (methods) shared by all instances of that type.
Example: "public Dog { … } defines the blueprint for all Dog objects."
Column Index
The second index used to access an element in a 2D array, representing the column position (e.g., matrix[row][col]).
Comparable Interface
A built-in Java interface with a compareTo() method that allows objects of a class to be compared for natural ordering; required for sorting with Arrays.sort() on custom objects.
Compile-Time Polymorphism
Polymorphism resolved by the compiler before the program runs, achieved through method overloading.
Also called: Static polymorphism
Compiler
A program that translates Java source code into bytecode; catches syntax errors before execution.
Compound Assignment Operator
An operator that combines an arithmetic operation with assignment; includes +=, -=, *=, /=, %=.
Example: "x += 5 is a equivalent to x = x + 5."
Conditional Statement
A control structure that executes different blocks of code depending on whether a condition evaluates to true or false.
Also called: Selection statement
Constant
A variable declared with final that cannot be reassigned after initialization.
Example: "final int MAX = 100; declares a whose value can never change."
Constructor
A special method with the same name as the class that is called when a new object is created; initializes the object's fields. Has no return type.
Example: "public Dog(String name) { this.name = name; } is a that sets the dog's name."
Data Hiding
The OOP principle of restricting direct access to an object's internal state by making fields private and providing public accessor methods.
Also called: Information hiding
Debugging
The process of finding and correcting errors (bugs) in a program.
Declaration
Specifying the data type and name of a variable without necessarily assigning it a value.
Example: "int count; is a that names the variable but does not assign a value."
Decrement Operator (--)
An operator that decreases a variable's value by 1.
Example: "i-- applies the to reduce i by one."
Default Constructor
A constructor that takes no parameters; Java provides one automatically only if no constructor is explicitly defined in the class.
double
A primitive data type that stores 64-bit floating-point numbers (decimal values); the default type for decimal literals in Java.
Example: " gpa = 3.85; stores a decimal number."
Dynamic Method Dispatch
The mechanism by which Java determines which overridden method to execute at runtime based on the actual type of the object, not the declared reference type.
else Statement
A conditional block that executes when the preceding if condition is false.
else-if Statement
A chained conditional that checks an additional condition when the preceding if condition is false.
Encapsulation
The OOP principle of bundling data (fields) and the methods that operate on that data into a single class, and restricting direct access to fields using access modifiers.
Also called: Data hiding
Enhanced for Loop
A simplified loop syntax for iterating over all elements of an array or collection without using an index variable.
Also called: for-each loop
Example: "for (int num : array) { System.out.println(num); } uses an to visit every element."
equals() Method
A method inherited from the Object class used to test whether two objects are logically equal; should be overridden in custom classes (use == only for primitives and reference identity).
Exception
An unexpected event or error condition that occurs during program execution, disrupting the normal flow.
Exception Handling
A mechanism using try, catch, and finally blocks to detect and respond to runtime errors so the program can continue or fail gracefully.
extends
The keyword used in Java to indicate that a class inherits from a superclass, gaining access to its non-private fields and methods.
Example: "class Cat Animal inherits all accessible fields and methods from Animal."
final
A non-access modifier that makes a variable constant (cannot be reassigned), a method non-overridable, or a class non-inheritable.
Example: " double PI = 3.14159; declares a constant that cannot change."
finally Block
A block of code that executes after the try and catch blocks regardless of whether an exception was thrown; used for cleanup operations.
for Loop
A loop with a built-in initialization, condition, and update expression, typically used when the number of iterations is known in advance.
Example: "for (int i = 0; i < 10; i++) { … } is a that runs exactly ten times."
Generics
A Java feature that allows type parameters to be specified for classes and methods, enabling type-safe collections such as ArrayList<String>.
Example: "ArrayList<Integer> uses to restrict the list to Integer values only."
get(int index)
An ArrayList method that returns the element at the specified position.
Getter Method
A public method that retrieves (reads) the value of a private instance variable.
Also called: Accessor method
Example: "public String getName() { return name; } is a for the name field."
HAS-A Relationship
A composition relationship indicating that one class contains an instance of another class as a field.
Example: "A Car Engine means the Car class holds an Engine object as a field."
Identifier
The name given to a class, variable, method, or other programming element; must begin with a letter, underscore, or dollar sign and cannot be a reserved keyword.
if Statement
A conditional statement that executes a block of code only if a specified boolean expression is true.
Example: "if (score >= 60) { System.out.println("Pass"); } uses an to print only when the score qualifies."
IllegalArgumentException
A runtime exception thrown when a method receives an argument that is inappropriate or falls outside expected bounds.
Immutable
An object whose state cannot be changed after creation. Java's String class is immutable — any apparent modification produces a new String object.
implements
The keyword used by a class to adopt an interface and provide concrete implementations for all of its abstract methods.
Example: "class Circle Shape must define all methods declared in Shape."
import
A keyword used to make classes from other packages available for use in the current file without using the fully qualified name.
Example: " java.util.ArrayList; allows ArrayList to be used without its full package name."
Increment Operator (++)
An operator that increases a variable's value by 1.
Example: "i++ applies the to add one to i."
Index
An integer value used to access a specific element in an array or ArrayList; arrays in Java are zero-indexed (first element is at index 0).
IndexOutOfBoundsException
A runtime exception thrown when an index used to access an array, String, or ArrayList is outside valid bounds.
Infinite Loop
A loop whose condition never becomes false, causing the program to execute the loop body indefinitely.
Inheritance
A mechanism allowing one class (subclass) to acquire the fields and methods of another class (superclass) using the extends keyword; models an IS-A relationship and enables code reuse.
Example: "class Dog extends Animal uses so Dog automatically has Animal's fields and methods."
Inheritance Hierarchy
The tree structure formed by classes and their parent/child relationships through inheritance.
Initialization
Assigning an initial value to a variable at the time of declaration.
Example: "int count = 0; performs by giving count a starting value."
Insertion Sort
A sorting algorithm that builds a sorted subarray one element at a time by inserting each new element into its correct position; O(n²) worst case, O(n) best case.
Instance
A specific object created from a class template using the new keyword.
Example: "new Car() creates an of the Car class."
Instance Variable
A non-static variable declared inside a class but outside any method; each object has its own separate copy.
Also called: Field, attribute
instanceof
An operator that tests whether an object is an instance of a specific class or interface; returns a boolean value.
Example: "if (animal Dog) checks whether animal currently refers to a Dog object."
Instantiation
The act of creating a specific object (instance) of a class using the new keyword.
int
A primitive data type that stores whole numbers (integers) from -2,147,483,648 to 2,147,483,647; the default type for integer literals in Java.
Example: " score = 95; declares a whole-number variable."
Integer Division
Division between two int values that truncates any fractional part and returns an integer result.
Example: "7 / 2 gives 3 because discards the decimal portion."
Interface
A completely abstract type in Java that defines a contract of method signatures (and constants); a class uses implements to adopt an interface and must provide concrete implementations for all its methods.
Example: " Runnable { void run(); } defines a contract any implementing class must fulfill."
IS-A Relationship
An inheritance relationship indicating that a subclass object is a type of its superclass; established with extends or implements.
Example: "A Dog Animal means every Dog object can be used wherever an Animal is expected."
Iteration
The process of repeating a block of code; each single repetition is called an iteration.
JVM (Java Virtual Machine)
The runtime engine that executes Java bytecode, enabling Java's "write once, run anywhere" principle by abstracting over the underlying hardware and OS.
Keyword
A reserved word in Java that has a predefined meaning and cannot be used as an identifier.
Example: "class, int, public, and return are each a that Java reserves for its own use."
Linear Search
A searching algorithm that sequentially checks each element from beginning to end until the target is found or the list is exhausted; works on unsorted data with O(n) time complexity.
Also called: Sequential search
Local Variable
A variable defined within a method, constructor, or block; only accessible within that scope and not initialized automatically.
Logic Error
A program error where the code compiles and runs without crashing but produces incorrect results due to flawed logic.
Logical Operator
An operator that combines boolean expressions; includes && (AND), || (OR), ! (NOT).
Loop
A control structure that repeatedly executes a block of code until a specified condition is no longer true.
Math Class
A built-in Java class providing static mathematical methods and constants such as Math.abs(), Math.sqrt(), Math.pow(), and Math.random().
Math.abs()
A static Math method that returns the absolute value of a number.
Math.max(a, b)
A static Math method that returns the larger of two values.
Math.min(a, b)
A static Math method that returns the smaller of two values.
Math.pow(base, exp)
A static Math method that returns the value of base raised to the power of exp as a double.
Math.random()
A static Math method that returns a pseudorandom double value between 0.0 (inclusive) and 1.0 (exclusive).
Math.sqrt()
A static Math method that returns the positive square root of a number as a double.
Merge Sort
A divide-and-conquer sorting algorithm that recursively divides the array into halves, sorts each half, and merges them back in sorted order; O(n log n) time complexity in all cases.
Method
A named block of statements inside a class that performs a specific task and can optionally return a value to the caller.
Example: "public int add(int a, int b) { return a + b; } is a that computes a sum."