lyc10031 / gitalk Goto Github PK
View Code? Open in Web Editor NEWmy gitalk
my gitalk
https://lyc10031.github.io/about.html
欢迎访问我的博客。 浮名浮利,虚苦劳神。叹隙中驹,石中火,梦中身。——苏轼《行香子·述怀》
Go的Interface 是一组method(方法)集,只要一个非interface类型数据实现了集合内的方法就能使用该interface直接看例子,struc继承的例子:12345678910111213141516171819202122232425262728293031323334353637383940...
https://lyc10031.github.io/document/2019/08/09/select_VS_switch.html
switch is used to make a decision based on a variable value of any type.switch用于根据任何类型的变量值做出决定。 Read this for more details:Go’s switch is more general than ...
视频已搬运到B站 视频链接YouTube链接B站链接SELECT SELECT fist_name,last_name FROM customers 从 customers 表中查找 fist_name,last_name SELECT last_name,fist_name,points ...
https://lyc10031.github.io/2019/08/21/Strings.html
Go 字符串处理的常用函数Go标准库中的strings和strconv两个包里面有一些最常用的字符串操作函数strings 包中的常用函数strings官方文档func Contains(s,substr string) bool字符串s中是否包含 substr 返回bool值123456789fmt.Print...
https://lyc10031.github.io/2019/09/17/go-scripts.html
翻转一个整数 输入123,返回321;输入-321返回-123 输入的整数要求是一个 32bit 有符号数,如果反转后溢出,则输出 01234567891011func reverse(x int) (num int) { for x != 0 { num = num*10 + x%10 x = x / ...
学习下goroutine的使用方法goroutine是Go并行设计的核心。goroutine说到底其实就是协程,但是它比线程更小,十几个goroutine可能体现在底层就是五六个线程,Go语言内部帮你实现了这些goroutine之间的内存共享。执行goroutine只需极少的栈内存 (大概是4~5KB) ,当然会...
原文地址本文是我的一些总结和记录。Socket介绍 Socket起源于Unix,而Unix基本哲学之一就是 “一切皆文件”,都可以用“打开open –> 读写write/read –> 关闭close”模式来操作。Socket就是该模式的一个实现,网络的Socket数据传输是一种特殊的I/O...
https://lyc10031.github.io/2019/09/02/gin%E8%B0%83%E7%94%A8%E6%B5%81%E7%A8%8B.html
文件树:my-gin1/├── conf│ └── app.ini├── main.go├── middleware├── models│ ├── models.go│ └── tag.go├── pkg│ ├── e│ │ ├── code.go│ │ └── msg.go│ ...
https://lyc10031.github.io/2019/08/22/go-RESTful.html
原文地址本文是我的一些总结和记录。RESTful RESTful,是目前最为流行的一种互联网软件架构。因为它结构清晰、符合标准、易于理解、扩展方便,所以正得到越来越多网站的采用。 REST(REpresentational State Transfer)这个概念,首次出现是在 2000年Roy...
https://lyc10031.github.io/document/2019/08/13/grep.html
grep ^vivek /etc/passwdgrep -E ‘word1|word2’ 文件名
https://lyc10031.github.io/2019/08/13/interface1.html
Go的Interface 是一组method(方法)集,只要一个非interface类型数据实现了集合内的方法就能使用该interface直接看例子,struct继承的例子:1234567891011121314151617181920212223242526272829303132333435363738394...
原文地址本文是我的一些总结和记录。Go 如何编写测试用例Go语言中自带有一个轻量级的测试框架testing,使用自带的go test命令来实现单元测试和性能测试。可以基于这个框架写针对相应函数的测试用例,也可以基于该框架写相应的压力测试用例。建议安装gotests插件自动生成测试代码 go get -u -v ...
https://lyc10031.github.io/2019/09/10/go-%E7%9F%A5%E8%AF%86%E7%82%B9.html
defer defer 是后进先出。panic 需要等defer 结束后才会向上传递。 出现panic会先按照defer的后入先出的顺序执行,最后才会执行panic。 例子1: package mainimport
https://lyc10031.github.io/2019/09/10/go-%E7%9F%A5%E8%AF%86%E7%82%B9.html#mpg
golang 的堆和栈var p *int //全局指针变量func f(){ var i int i = 1 p = &i //全局指针变量指向局部变量i}func f(){ p := new(int) //局部指针变量,使用new申请的空间 *p = 1}上面...
https://lyc10031.github.io/document/2019/08/13/go-channel.html
学习Go channels 的记录最近在YouTube上看一个GO 的学习视频。记录下学习过程的知识点。链接在这里:Learn Go Programming - Golang Tutorial for Beginners因为太长了,YouTube不能自动生成字幕。啃的生肉,有理解不恰当地方的欢迎指正废话不多说直接...
https://lyc10031.github.io/document/2019/08/13/go-channel.html
学习Go channels 的记录最近在YouTube上看一个GO 的学习视频。记录下学习过程的知识点。链接在这里:Learn Go Programming - Golang Tutorial for Beginners因为太长了,YouTube不能自动生成字幕。啃的生肉,有理解不恰当地方的欢迎指正废话不多说直接...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.