diff options
author | Rob Pike <r@golang.org> | 2009-12-16 10:29:53 +1100 |
---|---|---|
committer | Rob Pike <r@golang.org> | 2009-12-16 10:29:53 +1100 |
commit | aea97e0bd7da9cef1cc631ddbd3578a0877a4fcc (patch) | |
tree | 89f2452373bd20e8248aee25ea00a592177bca95 /doc/progs/helloworld3.go | |
parent | 881d6064d23d9da5c7ff368bc7d41d271290deff (diff) | |
download | golang-aea97e0bd7da9cef1cc631ddbd3578a0877a4fcc.tar.gz |
update tutorial.
R=rsc
CC=golang-dev
http://codereview.appspot.com/179063
Diffstat (limited to 'doc/progs/helloworld3.go')
-rw-r--r-- | doc/progs/helloworld3.go | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/doc/progs/helloworld3.go b/doc/progs/helloworld3.go index ea567fe1b..5655c7489 100644 --- a/doc/progs/helloworld3.go +++ b/doc/progs/helloworld3.go @@ -5,17 +5,17 @@ package main import ( - "./file"; - "fmt"; - "os"; + "./file" + "fmt" + "os" ) func main() { - hello := []byte{'h', 'e', 'l', 'l', 'o', ',', ' ', 'w', 'o', 'r', 'l', 'd', '\n'}; - file.Stdout.Write(hello); - file, err := file.Open("/does/not/exist", 0, 0); + hello := []byte{'h', 'e', 'l', 'l', 'o', ',', ' ', 'w', 'o', 'r', 'l', 'd', '\n'} + file.Stdout.Write(hello) + file, err := file.Open("/does/not/exist", 0, 0) if file == nil { - fmt.Printf("can't open file; err=%s\n", err.String()); - os.Exit(1); + fmt.Printf("can't open file; err=%s\n", err.String()) + os.Exit(1) } } |