Heads up! This post was written 10 years ago. Some information might be outdated or may have changed since then.
Last version of the time of writing this is 1.5. So we can download it from https://golang.org/dl/
curl -O https://storage.googleapis.com/golang/go1.5.linux-amd64.tar.gz After that we must unpack it into /usr/local tar -C /usr/local -xzf go1.5.linux-amd64.tar.gz After that we must set some
env variables. mkdir -p ~/go
echo "export GOPATH=$HOME/go" >> ~/.bashrc
echo "export PATH=$PATH:$HOME/go/bin:/usr/local/go/bin" >> ~/.bashrc
source ~/.bashrc And finally we have it: public class Main {
public static void main(String[] args) {
System.out.println("Hello, world!");
}
}