package main import ( "io" "net/http" ) func main() { http.HandleFunc("/dog/", func(res http.ResponseWriter, req *http.Request) { io.WriteString(res, ` DOG `) }) http.HandleFunc("/cat/", func(res http.ResponseWriter, req *http.Request) { io.WriteString(res, ` CAT `) }) http.ListenAndServe(":9000", nil) }