1/30
Vocabulary flashcards summarizing core Java terminology, syntax, and concepts introduced in CPS 209 Lecture 1.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Java Virtual Machine (JVM)
Runtime environment that executes Java bytecode, allowing the same program to run on many operating systems.
Java Development Kit (JDK)
Package that supplies the Java compiler, standard libraries, and developer tools required to build Java programs.
static typing
Rule that every variable and expression has a fixed, known type at compile time; type errors are caught before the program runs.
primitive data type (Java)
One of Java’s eight built-in value types—byte, short, int, long, float, double, char, boolean—that store simple data and have no methods.
byte (Java)
8-bit signed integer primitive; range −128 to 127.
char (Java)
16-bit unsigned primitive that stores a single Unicode character (0–65 535).
int (Java)
32-bit signed integer primitive; range −2 147 483 648 to 2 147 483 647.
long (Java)
64-bit signed integer primitive; range −9 223 372 036 854 775 808 to 9 223 372 036 854 775 807.
float (Java)
32-bit IEEE-754 single-precision floating-point primitive.
double (Java)
64-bit IEEE-754 double-precision floating-point primitive (same format Python uses for floats).
boolean (Java)
Primitive type that can hold only the values true or false.
overflow
Condition where an arithmetic result exceeds the numeric range of its type, causing wrap-around (e.g., huge int sums becoming negative).
main() method (Java)
public static void main(String[] args) – the entry point where a standalone Java program starts execution.
public (Java keyword)
Access modifier that makes a class, method, or field visible from any other class.
static (Java keyword)
Marks a member as belonging to the class itself rather than to instances; can be accessed without creating an object.
void (Java keyword)
Return-type specifier indicating a method returns no value.
System.out.println()
Standard library call that prints a line of text to the console; part of the PrintStream object out inside the System class.
String literal
Sequence of characters delimited by double quotes in Java source code, e.g., "Hello".
concatenation operator (+)
When at least one operand is a String, + joins the strings together instead of performing numeric addition.
type mismatch
Compile-time error that occurs when an expression’s type is incompatible with what the context expects.
control structure
Language construct such as if-else, switch, for, while, or do-while that alters the normal sequential flow of execution.
if-else statement (Java)
Selection structure that executes one block when a Boolean condition is true and an optional block when it is false.
switch statement
Multi-branch selection structure that chooses a block to execute based on the value of an integral or char expression.
case label (switch)
Specific value inside a switch that is compared to the control expression; followed by code and usually ended by break.
break (switch/loop)
Keyword that exits the nearest switch or loop immediately, preventing further fall-through or iterations.
for loop (Java)
Count-controlled loop with initialization; condition; update clauses executed in that order each iteration.
while loop
Pre-test loop that repeats its body as long as its Boolean condition evaluates to true before each iteration.
do-while loop
Post-test loop that executes its body once, then repeats while the condition remains true.
operator precedence (Java)
Hierarchy that determines the order in which operators are evaluated; parentheses override the default order.
logical operators
&& (AND), || (OR), and ! (NOT) used to combine or invert Boolean expressions.
printf (Java)
Formatted-output method that uses C-style specifiers (e.g., %s, %d, %.2f) to produce formatted text.