Skip to content

How to start a new project in golang?

$ go mod init carexample.com

This is produce a go.mod file

Next add a go file including main() function in it.

package main

import "fmt"

func main() {

fmt.println("Hello welcome to new cars example go lang application!")

}

How to run this?

go run .
Share

Leave a Reply

Your email address will not be published. Required fields are marked *

One short email when a new calculator or article goes live. No spam, and you can unsubscribe in one click.