2012-11-06 19 views

Odpowiedz

171

Opakowanie zawiera HasPrefix i HasSuffix.

import "strings" 

startsWith := strings.HasPrefix("prefix", "pre") // true 
endsWith := strings.HasSuffix("suffix", "fix") // true 

play.golang.org

Powiązane problemy