cloudaice / learnGo

there are something about Go Useage
MIT License
0 stars 0 forks source link

初始化和声明方法 #2

Open cloudaice opened 11 years ago

cloudaice commented 11 years ago

当对变量进行赋值的时候,如果左边既有已经声明过的变量,又有未声明过的变量, 比较好的解决方法是先执行一条var语句声明一下那个变量,然后使用 =统一赋值。