1/25
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai |
|---|
No analytics yet
Send a link to your students to track their progress
Iteration
The process of repeating a block of code multiple times based on a specific condition.
While loop
A control flow statement that allows code to be executed repeatedly based on a boolean condition.
Boolean expression
An expression that evaluates to true or false, used to control the flow of a while loop.
Initialization
The process of setting a variable to its initial value before entering a loop.
Update Step
A statement inside a loop that modifies the control variable in order to eventually meet the loop's termination condition.
Definite iteration
A loop structure, like the for loop, that is used when the number of iterations is known beforehand.
For loop header
The part of the for loop that contains initialization, boolean expression, and update step.
Variable scope
The context within a program where a variable can be accessed or used.
String indices
The positions of characters in a string, which start from 0 to length() - 1.
Nested iteration
A looping structure where one loop runs inside another, resulting in multiple iterations for each iteration of the outer loop.
Total iterations formula
A calculation for determining the number of times the inner loop executes: Total Iterations = (Outer count) ร (Inner count).
Coordinate Grid example
A demonstration of nested loops where pairs of coordinates are printed for a grid.
Dependent loops
Loops where the inner loop's execution range is determined by the variable from the outer loop.
Infinite loop
A loop that never ends because its termination condition is never met.
Off-by-One Error
A common programming mistake where a loop iterates one time too many or too few.
Phantom semicolon
An error where a semicolon is placed directly after the loop header, causing an empty loop body.
Modifying loop variables
Changing the control variable within the body of the loop when it is already being updated in the loop header.
Looping
The process of executing a block of code repeatedly.
Control flow statement
A statement that controls the order in which code is executed.
Digit extraction
A process of breaking down an integer into its individual digits using operators like modulus and division.
System.out.print()
A method in Java used to output text to the console.
StringIndexOutOfBoundsException
An error that occurs when trying to access an index of a string that is outside its valid range.
Length of a string
A property that returns the number of characters in a string.
Flowchart
A visual representation of the steps in a process or algorithm.
Integer variable
A variable type in Java that holds whole numbers.
Code block
A group of statements that are executed together.