An anonymous function has no name. You can define and call one immediately:
func() {
fmt.Println("Hello!")
}()
The () at the end calls the function right after defining it. Anonymous functions are useful when you need a quick, one-time function. You'll see them often with goroutines and as arguments to other functions.