A past puzzle — fully playable. 4 attempts, hints on wrong guesses.
stdle-136.go
1packagemain
2
3import"fmt"
4
5funcmain(){
6varainterface{}=1
7varbinterface{}=int64(1)
8fmt.Println(a==b)
9}
Interfaces
Answer & explanation
Console output
false
Why
Interface equality first compares the dynamic types. a holds an int and b holds an int64; even though both equal 1 numerically, the types differ, so the interfaces are not equal. Go never implicitly converts between numeric types, and that strictness extends to interface comparison.