exercism/go/two-fer/two_fer.go
2017-08-24 12:17:56 -05:00

14 lines
252 B
Go

package twofer
import "fmt"
// ShareWith just returns "One for <who>, one for me."
// if <who> is empty, use "you"
func ShareWith(who string) string {
ret := "One for %s, one for me."
if who == "" {
who = "you"
}
return fmt.Sprintf(ret, who)
}