There are 2 types of for loops; The 'standard' for loop which loops through a code block while a condition is true, executing some logic after every loop as well (usually incrementation).
example:
for(int i = 0; i < 10; i++) {
//Code block
}
this would execute the code block until the variable i is no longer less than 10; And will increment i by one after each execution of the code block. This type of for loop is commonly used for iterating through arrays of primitive types, grabbing elements by index.
another variation of the for loop (often referred to as a for-each loop) is used to pull elements out of a collection. This type of for-loop will only work with collections that implement the Iterable interface, and is essentially a limited iteration by the collections iterator.
for(Object element : collection) {
//Do something with the elementa
}