可以参考下牛客的IO练习,一般用bufio.NewScanner来获取整行输入 input := bufio.NewScanner(os.Stdin) for input.Scan() { data := input.Text() }
点赞 评论

相关推荐

牛客网
牛客企业服务