📌  相关文章
📜  go 遍历 Golang 中的数组 - Go 编程语言代码示例

📅  最后修改于: 2022-03-11 14:45:00.982000             🧑  作者: Mango

代码示例2
package main

import "fmt"

func main() {
    data := [...]string{"Ned", "Edd", "Jon", "Jeor", "Jorah"}
    for i := 0; i < len(data); i++ { //looping from 0 to the length of the array
        fmt.Printf("%d th element of data is %s\n", i, data[i])
    }
}