18 lines
314 B
Go
18 lines
314 B
Go
// 包声明,表示这是一个可执行的 Go 程序
|
|
package main
|
|
|
|
// 格式化输入输出,提供打印、扫描、格式化字符串等功能
|
|
import (
|
|
"fmt"
|
|
)
|
|
|
|
// main 函数是程序的入口点
|
|
func main() {
|
|
// 声明
|
|
var s string
|
|
// 赋值
|
|
s = "Wonder"
|
|
fmt.Printf("Hello and welcome, %s!\n", s)
|
|
|
|
}
|