[Go]打印结构体

bs, _ := json.Marshal(student)
var out bytes.Buffer
json.Indent(&out, bs, "", "\t")
fmt.Printf("student=%v\n", out.String())

你可能感兴趣的:(Go,打印结构体,打印,结构体,struct,json)