package main import ( "fmt" "strconv" "time" ) func main () { timestamp := time.Now().Unix() fmt.Println("当前时间戳=",timestamp) fmt.Println("时间戳长度=",len(strconv.FormatInt(timestamp, 10))) }