Skip to content

Instantly share code, notes, and snippets.

@mbonell
Created August 21, 2018 05:20
Show Gist options
  • Save mbonell/ce59503578ca649c043dee8e56135196 to your computer and use it in GitHub Desktop.
Save mbonell/ce59503578ca649c043dee8e56135196 to your computer and use it in GitHub Desktop.
package main
import (
"io"
"net/http"
)
func hello(w http.ResponseWriter, r *http.Request) {
io.WriteString(w, "Hello World!")
}
func main() {
http.HandleFunc("/", hello)
http.ListenAndServe(":8000", nil)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment