Go: Range is by Value

> TL;DR: The value for each item in a range loop is not by reference. Instead, use the index index := range foos.Bars and index to the item &foos.Bars[index]. I learned a practical lesson today about how the range keyword works in Go. Here's…

Whimsy

As it turns out, I'm really bad at following through with plans. I recently intended to dig through algorithms in Go, but here I find myself doing whimsical [https://github.com/johncoder/whimsy] things with my time instead. A couple of years ago I had a dubious amount…

Go Algorithms: Sorts

I started with Go's sort [http://golang.org/pkg/sort/] package for some inspiration on how to build the API for my implementations. It is nice to be able to look at other approaches, especially when I'm more accusotmed to doing things in Node.js or…

Algorithms in Go

Lately I have been learning a lot about Go [http://golang.org]. I decided a great independent study subject would be to review Algorithms, Fourth Edition [http://algs4.cs.princeton.edu/home/] in the context of Go. However, this presents a few obsticles that ups the degree of difficulty. Most…