Hello World with Go!

Hello everyone,

today i will show you, how to print “hello World” with GoLang

before starting this tutorial, make sure you have installed golang.

i’ll show you how to install golang firts.

1.Download golang at web Golang

red for Windows, yellow f…


This content originally appeared on DEV Community and was authored by M Fariz Wisnu prananda

Alt Text
Hello everyone,

today i will show you, how to print "hello World" with GoLang

before starting this tutorial, make sure you have installed golang.

i'll show you how to install golang firts.

1.Download golang at web Golang
Alt Text
red for Windows, yellow for MacOs, and Green for Linux

i'll show you how to install golang at Windows

2.After you finished download go , setting gopath in your computer like this
Alt Text

3.Now you can start coding!

4.Open Your VS Code , make new folder for code golang

5.Open CMD with ctrl + j , and type like this
go mod init belajar-golang
for make go mod

6.after typing it, there are will be a new file called name go.mod
Alt Text

7.then create new file named main.go
8.then type code like this

package main

import "fmt"

func main(){
    fmt.Println("Hello World!")
}

9.and after type code , run the file main.go with command like this
go run main.go

10.The result will be like this
Alt Text

And that the way to print "Hello World" with Golang


This content originally appeared on DEV Community and was authored by M Fariz Wisnu prananda


Print Share Comment Cite Upload Translate Updates
APA

M Fariz Wisnu prananda | Sciencx (2021-09-01T09:11:15+00:00) Hello World with Go!. Retrieved from https://www.scien.cx/2021/09/01/hello-world-with-go/

MLA
" » Hello World with Go!." M Fariz Wisnu prananda | Sciencx - Wednesday September 1, 2021, https://www.scien.cx/2021/09/01/hello-world-with-go/
HARVARD
M Fariz Wisnu prananda | Sciencx Wednesday September 1, 2021 » Hello World with Go!., viewed ,<https://www.scien.cx/2021/09/01/hello-world-with-go/>
VANCOUVER
M Fariz Wisnu prananda | Sciencx - » Hello World with Go!. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/09/01/hello-world-with-go/
CHICAGO
" » Hello World with Go!." M Fariz Wisnu prananda | Sciencx - Accessed . https://www.scien.cx/2021/09/01/hello-world-with-go/
IEEE
" » Hello World with Go!." M Fariz Wisnu prananda | Sciencx [Online]. Available: https://www.scien.cx/2021/09/01/hello-world-with-go/. [Accessed: ]
rf:citation
» Hello World with Go! | M Fariz Wisnu prananda | Sciencx | https://www.scien.cx/2021/09/01/hello-world-with-go/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.