<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://aznot.com/index.php?action=history&amp;feed=atom&amp;title=OpenWest_2014%2FGo</id>
	<title>OpenWest 2014/Go - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://aznot.com/index.php?action=history&amp;feed=atom&amp;title=OpenWest_2014%2FGo"/>
	<link rel="alternate" type="text/html" href="https://aznot.com/index.php?title=OpenWest_2014/Go&amp;action=history"/>
	<updated>2026-04-30T05:51:33Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://aznot.com/index.php?title=OpenWest_2014/Go&amp;diff=96&amp;oldid=prev</id>
		<title>Kenneth at 15:12, 17 May 2014</title>
		<link rel="alternate" type="text/html" href="https://aznot.com/index.php?title=OpenWest_2014/Go&amp;diff=96&amp;oldid=prev"/>
		<updated>2014-05-17T15:12:20Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Ken Thompson - Unix&lt;br /&gt;
&lt;br /&gt;
Google&lt;br /&gt;
&lt;br /&gt;
Gopher - GopherCon 2014&lt;br /&gt;
&lt;br /&gt;
Utah Go Users Group - http://www.utahgophers.com&lt;br /&gt;
* Tues. May 13 @ 6:30pm&lt;br /&gt;
&lt;br /&gt;
The Go Programming Language Specification - The Go Programming Language - http://golang.org/ref/spec&lt;br /&gt;
&lt;br /&gt;
Justifications:&lt;br /&gt;
* C++ too complex&lt;br /&gt;
* compilation too slow&lt;br /&gt;
* programming to difficult&lt;br /&gt;
* easy over safety and efficiency&lt;br /&gt;
&lt;br /&gt;
Issues:&lt;br /&gt;
* Name &amp;quot;Go&amp;quot; is ungoogable / hastagable (use golang) *** MOST ANNOYING ***&lt;br /&gt;
&lt;br /&gt;
Companies who use Go:&lt;br /&gt;
* PayPal&lt;br /&gt;
* Github&lt;br /&gt;
* MongoDB&lt;br /&gt;
* Canonical&lt;br /&gt;
* Mozilla&lt;br /&gt;
* Stack Overflow&lt;br /&gt;
* Puppet Labs&lt;br /&gt;
&lt;br /&gt;
Twitter: #golang&lt;br /&gt;
 &lt;br /&gt;
Prediction: Will become dominant language for LaaS and PaaS in 24 months&lt;br /&gt;
&lt;br /&gt;
Go is...&lt;br /&gt;
* Compiled&lt;br /&gt;
* Strongly typed&lt;br /&gt;
* Statically typed&lt;br /&gt;
* Garbage collected&lt;br /&gt;
* Similar to C syntax&lt;br /&gt;
* Capable of statically verified duck typing (via interfaces)&lt;br /&gt;
* Open Source&lt;br /&gt;
&lt;br /&gt;
Hello World:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package main&lt;br /&gt;
&lt;br /&gt;
import &amp;quot;fmt&amp;quot;&lt;br /&gt;
&lt;br /&gt;
func main() {&lt;br /&gt;
    fmt.Println(&amp;quot;Hello World&amp;quot;)&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note: Semi colons are optional.&lt;br /&gt;
&lt;br /&gt;
Variables:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pakcage main&lt;br /&gt;
&lt;br /&gt;
import &amp;quot;fmt&amp;quot;&lt;br /&gt;
&lt;br /&gt;
func main() {&lt;br /&gt;
    var i, j int = 1, 2&lt;br /&gt;
    k := 3&lt;br /&gt;
    c, python, java := true, false, &amp;quot;no!&amp;quot;&lt;br /&gt;
    fmt.Println(i, j, k, c, python, java)&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When variables are first initialized, they are always set to their &amp;quot;zero&amp;quot; value.  There isn&amp;#039;t a null value?&lt;br /&gt;
&lt;br /&gt;
Comments:&lt;br /&gt;
 // comments use C&amp;#039;s syntax&lt;br /&gt;
 /* multi line comment */&lt;br /&gt;
&lt;br /&gt;
Functions:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package main&lt;br /&gt;
&lt;br /&gt;
import &amp;quot;fmt&amp;quot;&lt;br /&gt;
&lt;br /&gt;
func add(x int, y int) int {&lt;br /&gt;
    return x + y&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
func main() {&lt;br /&gt;
    fmt.Println(...??&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Types:&lt;br /&gt;
* bool&lt;br /&gt;
* string&lt;br /&gt;
* int, int32, ...&lt;br /&gt;
* uint, uint8, ...&lt;br /&gt;
* byte&lt;br /&gt;
* rune alias for int32&lt;br /&gt;
* float32&lt;br /&gt;
* complex64&lt;br /&gt;
&lt;br /&gt;
Type conversions - no implicit conversions (have to manually cast)&lt;br /&gt;
&lt;br /&gt;
Looping - Go only has &amp;#039;for&amp;#039;&lt;br /&gt;
 for i := 0; i &amp;lt; MAX ; i++ { ... }&lt;br /&gt;
&lt;br /&gt;
While:&lt;br /&gt;
 for ; sum &amp;lt; 1000;  { sum += sum }&lt;br /&gt;
 for sum &amp;lt; 1000 { sum += sum }&lt;br /&gt;
&lt;br /&gt;
If/Else&lt;br /&gt;
 if x &amp;lt; 0 { ... }&lt;br /&gt;
 else if x &amp;gt; 0 { ... }&lt;br /&gt;
 else { ... }&lt;br /&gt;
&lt;br /&gt;
Don&amp;#039;t fear Go pointers&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
type Coordinate struct {&lt;br /&gt;
  X int&lt;br /&gt;
  Y int&lt;br /&gt;
  Z int&lt;br /&gt;
  name string&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
func GCP() *Coordinate {&lt;br /&gt;
  return &amp;amp;Coordinate{1, 2, 3, &amp;quot;foo&amp;quot;}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
func main() {&lt;br /&gt;
 var cp *Coorindate = getCCP()&lt;br /&gt;
  fmt.Println(cp)&lt;br /&gt;
 fmt.Printf(&amp;quot;%T\n&amp;quot;, cp)&lt;br /&gt;
 ...&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Slices&lt;br /&gt;
&lt;br /&gt;
Range&lt;br /&gt;
 var pow = []int{1, 2, 3}&lt;br /&gt;
 func main() {&lt;br /&gt;
   for i, v := range pow {&lt;br /&gt;
     fmt.Printf(&amp;quot;%d: %d\n&amp;quot;, i, v)&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 for _, v := range pow { ... }&lt;br /&gt;
 // underscore is special&lt;br /&gt;
&lt;br /&gt;
Maps&lt;br /&gt;
&lt;br /&gt;
Access is marked public/private by the first letter of the member.  Public is capital.  Private is lowercase.&lt;br /&gt;
&lt;br /&gt;
No assertions?&lt;br /&gt;
&lt;br /&gt;
Structs in Go - instead of classes in Object Oriented Programming&lt;br /&gt;
 type House struct { }&lt;br /&gt;
 func (h House) GetHouseName() string { } //method defined outside of struct, but works on House&lt;br /&gt;
&lt;br /&gt;
Interfaces are super important in Go.&lt;br /&gt;
 type noiser interface{&lt;br /&gt;
    GetNoise() string&lt;br /&gt;
 }&lt;br /&gt;
 type Cow struct{}   // empty structs&lt;br /&gt;
 type Fox struct{}&lt;br /&gt;
 func (f Fox) GetNoise() string { ... }&lt;br /&gt;
&lt;br /&gt;
[[Category:Go]]&lt;/div&gt;</summary>
		<author><name>Kenneth</name></author>
	</entry>
</feed>