Skip to content

Instantly share code, notes, and snippets.

@wm
Created November 8, 2015 01:46
Show Gist options
  • Save wm/467c11c14d73ecfce570 to your computer and use it in GitHub Desktop.
Save wm/467c11c14d73ecfce570 to your computer and use it in GitHub Desktop.
calling-vs-casting-3
package main
import (
"fmt"
"net/http"
)
func Yolo(w http.ResponseWriter, r *http.Request) {
fmt.Fprintln(w, "YOLO")
}
func main() {
http.Handle("/yolo2", http.HandlerFunc(Yolo))
http.ListenAndServe(":3000", nil)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment