For-each loop is used to iterate through elements of arrays and collections (like ArrayList). It is also known as the enhanced for loop.