這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。多態用法package main//一種事物的多種形態,都可以按照統一的介面進行操作//多態import ( "fmt" "math/rand" "sort")type Student struct { Name string Id string Age int sortType int}type Book
這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。由於各種問題,國內使用 go get 安裝 golang 官方包可能會失敗,如我自己在安裝 collidermain 時,出現了以下報錯: $ go get collidermainpackage golang.org/x/net/websocket: unrecognized import path "golang.org/x/net/websocket" (https fetch: Get
這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。Mac OS 開發環境 Terminal 配置---[TOC]### Terminal 主題選擇Mac OS 內建主題已經很不錯很好看,如果不滿意系統內建主題,可以自訂配置。這裡推薦下面的設定檔,下載下來,直接匯入就好。[https://github.com/chriskempson/tomorrow-theme](https://github.com/chriskempson/tomorrow-theme)### Vim 配置.
這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。參考:https://stackoverflow.com/questions/31337891/net-http-http-contentlength-222-with-body-length-0問題闡述:在使用 golang http 包發送 post 請求時出現報錯,類似 http: ContentLength=355 with Body length 0。大意是 ConlentLength 設定了一定長度,但是在讀取
這是一個建立於 的文章,其中的資訊可能已經有所發展或是發生改變。go get github.com/alphazero/Go-Redis go get github.com/simonz05/godis go get github.com/garyburd/redigo go get github.com/gosexy/redis go get cgl.tideland.biz/redis 目前這五種 開源庫redigo的使用 github地址: