← Back to archive

Stdle #131 · interfaces · 2026-10-15

What does this Go snippet output?

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

package main
import "fmt"
type N struct{ V int }
func main() {
a := &N{1}
b := &N{1}
var x, y interface{} = a, b
fmt.Println(x == y)
}
Interfaces
4 attempts left

Answer & explanation