In any programming language, measuring the execution time is always useful to get a glimpse of what is going on in a piece of code. Here is a quick snippet to measure the execution time in milliseconds in Golang. package main import (
"log"
"time"
) func main() {
start := time.Now().UnixNano() / int64(time.Millisecond) // do something
time.Sleep(1 * time.Second)