Use for range to iterate over values or indices without manual index management, and use for i := 0; i < len(slice); i++ when you need to modify elements or access the index explicitly.
// Read-only iteration with index and value
for i, v := range slice {
fmt.Println(i, v)
}
// Modification requires explicit index loop
for i := 0; i < len(slice); i++ {
slice[i] = slice[i] * 2
}