package a import "fmt" type Sayer interface { Say() string } type Formal struct{} func (p Formal) Greet(s interface{Sayer}) string { return fmt.Sprintf("Hello, %s", s.Say()) }