Use range based for loops and type inference