How foreach or Enhanced for loop works in Java? Example

How foreach or Enhanced for loop works in Java? Example