Get argument in golang.
import (
"fmt"
"os"
)
func main() {
fmt.Println(len(os.Args), os.Args)
}
Cheatsheet collection for go, rust, python, shell and javascript.
Get argument in golang.
import (
"fmt"
"os"
)
func main() {
fmt.Println(len(os.Args), os.Args)
}