Google GO Tutorial

Topics on common programming languages
Post Reply
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Google GO Tutorial

Post by Neo » Sun Jan 24, 2010 9:59 pm

go-logo-black.png
go-logo-black.png (8.65 KiB) Viewed 3482 times
a systems programming language
expressive, concurrent, garbage-collected


Go is …
… simple

Code: Select all

package main

import "fmt"

func main() {
  fmt.Printf("Hello, ??\n")
}
… fast

Go compilers produce fast code fast. Typical builds take a fraction of a second yet the resulting programs run nearly as quickly as comparable C or C++ code.
… safe

Go is type safe and memory safe. Go has pointers but no pointer arithmetic. For random access, use slices, which know their limits.
… concurrent

Go promotes writing systems and servers as sets of lightweight communicating processes, called goroutines, with strong support from the language. Run thousands of goroutines if you want—and say good-bye to stack overflows.
… fun

Go has fast builds, clean syntax, garbage collection, methods for any type, and run-time reflection. It feels like a dynamic language but has the speed and safety of a static language. It's a joy to use.
… open source

GO is a new programming language developed by Google. GO is based primarily on the C platform but is more refined and more advanced, and more in sync with the recent technology enhancements on a hardware level. The goal of this language is to make software development Simple, Fast, Safe, Concurrent, Fun and Open Source.

GO is a Simple Programming Language
One of the first things we see with Google for any product is "simplicity". This company definitely believes in making things simple and easy. So as most programming languages have a particular syntax that you need to understand, GO has a similar, but much simpler and predictable as compared to C, C++, etc...

Fast Compilers
One of the slowest process of most programming languages is compilation. It takes a long time to compile the code, and that has just changed. With GO compilers, typical builds are compiled within fraction of a second. Which really is something that all programmers have been wanting since a long time.

GO is concurrent
Which may mean a lot, specially if you are building a program that needs multiple processes to run at the same time. Go promotes writing systems and servers as sets of lightweight communicating processes, called goroutines, with strong support from the language. Run thousands of goroutines if you want—and say good-bye to stack overflows.

LEARN GO PROGRAMMING LANGUAGE
There is a lot of information available for you to get your feet wet. Here are some slides from a 3-day course about Go: Day 1, Day 2, Day 3.

[media]http://www.youtube.com/watch?v=rKnDgT73v8s[/media]

Here is the PDF used during the video:

The documentation of GO programming language is really very comprehensive and also "searchable". Here is the Go language specification: http://golang.org/doc/go_spec.html

Ok, so ready to get started?
Step 1 is to install GO and other required components (GCC, the standard C libraries, the parser generator Bison, make and the text editor ed installed). Visit http://golang.org/doc/install.html for installation instructions.
Link: Official Mailing List to discuss Go Language
Link: Go Bugs and Issue Tracker

Note:
This is not the official documentation of the language. Original documentation about Go Programming Language can be found at http://golang.org.
Post Reply

Return to “.Net & Other Programming”