Tag Archives: golang

Blackjack in Golang on GitHub

The code I’ve been hacking in my posts Test Driven Development (TDD) in golang and Refactoring and Inheritance in golang is now available on github at https://github.com/jimbelton/cards. A first playable blackjack game is included. If you look at the git history, you can see how … Continue reading

Posted in Uncategorized, golang programming | Tagged , , , | Leave a comment

Refactoring and Inheritance in golang

One complaint people have with go is that it isn’t fully object oriented. It turns out that go handles 95% of what you’d want to use inheritance for with two constructs: interfaces, and embedding. Interfaces allow you to define heritable … Continue reading

Posted in golang programming | Tagged , , , | 1 Comment

Test Driven Development (TDD) in golang

I’m going to try a little TDD in go. TDD is a methodology that allows rapid development of bug free code. It’s a technique that I regularly use when programming in C, python, or Java, but I have yet to … Continue reading

Posted in golang programming | Tagged , , | 2 Comments

Using golang on Windows

To install the latest version of the Go programming language (golang): Browse to the downloads page: https://golang.org/dl/ Click on the latest go.#.##.windows-amd64.msi and save it Open the msi file with Windows explorer and follow the installation instructions To test it out, … Continue reading

Posted in golang programming | Tagged , , , , | Leave a comment

CLI, Directories, and Gob in Go

Building on my last post, Playing with Go (AKA golang), I’m going to hack a command line interface (CLI), do some directory parsing, and add some code to read back the note I serialized to a file using gob. To … Continue reading

Posted in golang programming | Tagged , , , , , , , | Leave a comment

Playing with Go (AKA golang)

To installing Go on debian Linux: sudo apt-get install golang Check your version like this: go version > go version go1.3.3 linux/amd64 Using you favorite text editor (IDEs are for the weak), create a file with the .go extension. I’ll … Continue reading

Posted in golang programming | Tagged , , , , | 1 Comment