请问go语言能不能直接从数组里解构元素出来赋值给变量?

formalin14 · · 3969 次点击
这个需求的意义是什么,数据库查找?
#2
更多评论
找到一个模块,搞定了: ![image.png](https://static.studygolang.com/210511/d8009525c85dc0a82fdb969cdd4f6cc0.png) ![image.png](https://static.studygolang.com/210511/5574f13a51e537621c79d47e6d98d9d1.png) `go get github.com/googleinterns/sensor-historian`
#1
slclub
坚持就是胜利
已知的是这样写 id, name, age := row[0], row[1], row[4] 封函数也不太好封,返回值数量不定
#3