29

golang碎片整理之 fmt.Scan-霍帅兵的博客

 5 years ago
source link: https://blog.51cto.com/13766835/2389523
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
本文介绍了从golang语言中fmt包从标准输入获取数据的Scan系列函数、从io.Reader中获取数据的Fscan系列函数以及从字符串中获取数据的Sscan系列函数的用法。Scan系列go语言fmt包下有fmt.Scan、fmt.Scanf、fmt.Scanln三个函数,可以在程序运行过程中从标准输入获取用户的输入。fmt.Scan语法funcScan(a...interface{})(nin

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK