← Back to archive

Stdle #110 · interfaces · 2026-09-24

What does this Go snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

package main
import "fmt"
type E struct{}
func (e *E) Error() string { return "boom" }
func find() error {
var p *E
return p
}
func main() {
fmt.Println(find() == nil)
}
Interfaces
4 attempts left

Answer & explanation