Now i will teach u to write our firs Hello World! program on Go language. And, i'm sure, that you like Go as it did I. So let's start!
So make file, and name it hello.go. Open it with any of text editors and paste (or write - as u want) those code:
package main
import fmt "fmt"
func main() {
fmt.Printf("Hello, world!\n");
}
and save it. Than in terminal enter (with command cd) into directory, where you save Hello World! file, and write in terminal:
8g hello.go
8l hello.8
./8.out
ATTENTION! If it didn't works instead 8 write 6. It's for the 64-bit x86 systems. If u have 32-bit x86, and more - it should work with 8.
You'r a cool Go programmer now ;) Wait for a new tutorials and don't forget to subscribe! :)
how to get go compiler for ubantu?
ReplyDelete