Python is significantly faster than running go run myfile.go. However, that's not Go's intended use case, really. That's more for debugging along the way, since go run does include the compilation each time.
I think it's interesting to compare the difference between go run and executing the compiled go executable, so the third set of each (ex: ./1_1) is go running the resulting compiled executable 100 times.
I'm a Sr. Software Engineer at Flashpoint. I specialize in Python and Go, building functional, practical, and maintainable web systems leveraging Kubernetes and the cloud. Blog opinions are my own.
Python is significantly faster than running
go run myfile.go. However, that's not Go's intended use case, really. That's more for debugging along the way, sincego rundoes include the compilation each time.I think it's interesting to compare the difference between
go runand executing the compiled go executable, so the third set of each (ex:./1_1) is go running the resulting compiled executable 100 times.Ooooh ok that makes sense. Cool!