- 博客(7)
- 资源 (4)
- 收藏
- 关注
原创 浅谈程序员常去的社区
国外Hacker News世界顶级英文技术博客或者科技新闻的聚集地,科技圈里发生的事情或者特别有价值的技术博客都会被及时收录。既然是hacker人员,真的有必要时刻关注网站的新闻内容。你可以从用户提交的数据中找到适合你的学习资源,比如文章、图像视频以及对一些问题的讨论。网址:https://news.ycombinator.com/newsGoogle+ CommunitiesGoogle+社区只需
2017-12-28 13:25:59 3061 1
原创 Go的unsafe包
Go官方包提供了一个unsafe包,在这个包里面有含够绕开Go程序类型安全的操作。 既然是unsafe包,使用起来一定要特别小心。尽管unsafe有点危险,但是它也难以置信的有用。unsafe的操作:A pointer value of any type can be converted to a Pointer.A Pointer can be converted to a pointer v
2017-12-22 10:46:56 936
原创 值得期待:Go对WebAssmbly的完全支持
WebAssembly获得了所有浏览器的一致支持, Chrome 和 Firefox 已经原生支持 WebAssembly,Edge 和 Safari 也在预览版中加入了 WebAssembly 支持。Go很快也会对WebAssembly进行支持,目前还处理开发阶段。社区已经有对应的指导文档,下面就是社区的部分指导步骤。 ” Compiling Go code to wasm is also d
2017-12-20 17:32:22 5513 1
原创 探究Go类型参数的函数
Go语言中,函数的定义与函数的调用方可以不一致。换句话说,缺乏runtime类型安全就允许函数调用端的参数与函数定义端的参数不一致。Go不支持函数的多态特性,这就决定了无法根据参数的类型或者个数定义多态的函数。但是,可以定义多态参数。Go构建函数中,append, close, delete, copy, cap 和 len函数都使用了参数多态。Go编程中,有时候为了达到代码的简洁美而编写一些泛化的
2017-12-20 15:52:16 1936
原创 Go反射调用方法
Go提供了一个很重要的特性就是反射机制,反射机制对应处理一些特殊的应用场景非常实用。下文是Go反射调用函数的代码片段。func callReflect(any interface{}, name string, args... interface{}) []reflect.Value{ inputs := make([]reflect.Value, len(args)) for i,
2017-12-20 10:01:22 5170
原创 Go字符类型转化为整型或者整型转化为字符类型
Go语言很容易地实现了字符类型到整型类型的转化,反过来也一样。见下文代码实现。 i := 10 fmt.Printf("i convert string : %s", strconv.Itoa(i)) s := "1000" // The bitSize argument specifies the integer type // that the result
2017-12-20 09:56:51 3143
原创 Go sha256使用实例介绍
SHA-256安全散列算法SHA(Secure Hash Algorithm)是美国国家安全局 (NSA) 设计,美国国家标准与技术研究院(NIST) 发布的一系列密码散列函数,包括 SHA-1、SHA-224、SHA-256、SHA-384 和 SHA-512 等变体。主要适用于数字签名标准(DigitalSignature Standard DSS)里面定义的数字签名算法(Digital Sig
2017-12-17 16:05:59 20876
Machine Learning With Go
2017-10-22
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人